Getting a kerberos ticket

Mike McGavin jester at NOSPAM.mcsnospam.vuw.netNOSPAM.nz
Tue Jan 28 19:28:23 EST 2003


Hello everyone.

Is anyone able to direct me to a python module for interacting with 
kerberos 5? I have a situation where I need to connect to a postgresql 
database using kerberos authentication from a python CGI script.

When connecting locally and interactively I can run kinit beforehand to 
authenticate and get the ticket and so on, so there haven't been any 
problems. (I've been using PyGreSQL to connect to postgres.) It's more 
awkward with a CGI script, though, because it's running in an 
independent environment on a web server that I don't have much access to 
besides running CGI scripts. There's no way that I can run kinit without 
an ugly and inefficient hack that I'd prefer to avoid.

I think what I need to do is get a ticket issued whenever one is 
needed... preferably not every time the script loads, although that 
would be a hack I could live with for now.

Does anyone have any experience with this, and possibly some sample code?


Thanks for any help.
Mike.





More information about the Python-list mailing list