Skip Navigation

Friday August 2nd, 2013

WebAuth: Writing a Program to Check Authentication

Summary: Use this guide to help you write a program to check for UCInetID Authentication.

The current name of the server is 'login.uci.edu'

Things to consider before WebAuthing an application:

Things to decide before WebAuthing an application:

Things to make sure not to do while WebAuthing an application:

The steps that need to be followed for a program that checks authentication are as follows:

  1. Get value of ucinetid_auth cookie or GET variable if either exists
  2. Send HTTP GET with the value of 'webauth_check?ucinetid_auth=UCINETID_AUTH' (with optional '&return_xml=true') to the authentication host
  3. Parse the response
  4. Check to make sure there is a value for the UCInetID
  5. Check value of auth_fail if there is no UCInetID if the reason for failure matters
  6. Check to make sure the auth_host value matches the IP number of the browser currently accessing the program
  7. Check the times of the login to guess at validity:
    • age_in_seconds for the overall age of the login
    • max_idle_time for the amount of time between checks
  8. Check any local authorization
  9. Grant access to any materials

Here is a list of all the values returned by webauth_check along with a list of error code meanings.

If you find it useful, here is a flowchart of the web authentication procedure.