[pubcookie-users] pubcookie authentication with a script

Nathan Dors dors at cac.washington.edu
Tue Mar 20 10:00:42 PDT 2007


If it's just a script, it may be easier, and better in the long 
term, to port it to the web (medium difficult) and use web-based 
authentication (easy) than keep the script the way it is and port 
web-based authentication to it (super difficult). Tough to say, 
not knowing much about the script.

If you really want to minimize changes to the script's UI while 
adding UW NetID-based authentication, you're probably better off 
using the UW Kerberos service to authenticate users directly. I 
don't know what Kerberos-based solutions exist for Python, but 
Google points out a "pykpass" extension for Kerberos 5 
authentication. That sounds warm. Email kerberos-support at u if you 
go that route and need to bounce around some ideas.

Of course, Kerberos has its own complexity, and adding it to your 
script may present a significant challenge (back to super 
difficult). If so, that may leave you with few options but to port 
the script to the web.

Hope this helps.

-Nathan

On Tue, 20 Mar 2007, Noah Hoffman wrote:

> Hi Nathan,
>
> Thanks for the reply. If I had the time, I'd love to develop our application 
> for the web. Short of that, if the simple answer is that authentication has 
> to be performed from a  browser, then that's the way it goes. I though that 
> there might be a way to interact with the proxy server programmatically, 
> something along the lines of this:
>
> http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/301740
>
> Alternatively, would it be possible to open a browser when the application 
> launches, direct the browser to a site defining the requirements for 
> authentication, ask the user to authenticate via the browser, then look for 
> the "granting cookie" in the filesystem?
>
> I'm obviously beyond my expertise here, but I though it was worth a shot.
>
> Thanks again,
> Noah
>
>
> On Mar 20, 2007, at 8:47 AM, Nathan Dors wrote:
>
>> Hi Noah,
>> 
>> Any thoughts of converting your simple text-based UI into a web-based UI? 
>> Pubcookie is intended for web-based authentication only.
>> 
>> -Nathan
>> 
>> On Mon, 19 Mar 2007, Noah Hoffman wrote:
>> 
>>> Hello-
>>> 
>>> I a UW user, and I'm trying to come up with a scheme for authentication to 
>>> a database in a clinical lab. I have a set of python scripts with a simple 
>>> text-based UI that can be run on client machines to mediate interactions 
>>> with a MySQL server. All of the potential users have a UW NetID. Is there 
>>> any reasonably straightforward way that my python scripts can use UW NetID 
>>> authentication via pubcookie for user authentication?
>>> 
>>> Thanks,
>>> Noah
>


More information about the pubcookie-users mailing list