Skip to end of metadata
Go to start of metadata
Table of Contents

The pycas CAS client provides CAS authentication for your Python CGI web application.

Download the Python CAS client here.


1) Add four lines to your Python Web app like this,

import pycas
CAS_SERVER  = "https://casserver.mydomain"
SERVICE_URL = "http://webserver.mydomain/cgi-bin/"
status, id, cookie = login(CAS_SERVER, SERVICE_URL)

2) Process the returned variables,

status carries the success or failure status.
id is the user's account name.
cookie is the header string to send to the client if it's not empty.

For more information, see comments in the Python code.

  • No labels