-
Notifications
You must be signed in to change notification settings - Fork 8
jathanism/python-opensso
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
python-opensso - Python interface to OpenSSO/OpenAM REST API Code borrowed and reworked from django-opensso by nsb https://github.com/nsb/django-opensso The opensso.py module provided by django-opensso had a dependency upon python-restclient which in turn had a dependency upon python-httplib2. I removed these dependencies in favor of Python's urllib2, which is part of the Standard Library. Since we're just doing basic HTTP GET calls, I felt that eliminating the external dependencies made this library as lightweight as possible. For REST API documentation please see "The OpenSSO REST Interface in Black/White" http://blogs.sun.com/docteger/entry/opensso_and_rest This is not a complete implementation. Only the end-user functionality has been included. None of the administrative methods are implemented... yet. Example: >>> import opensso >>> o = opensso.OpenSSO('https://example.com/opensso') >>> token = o.authenticate('jathanism', 'password') >>> o.is_token_valid(token) True >>> attrs = o.attributes(token) >>> attrs.attributes.keys() ['telephonenumber', 'distinguishedname', 'inetUserStatus', 'displayname', 'cn', 'dn', 'samaccountname', 'useraccountcontrol', 'objectguid', 'userprincipalname', 'name', 'objectclass', 'sun-fm-saml2-nameid-info', 'sn', 'mail', 'sun-fm-saml2-nameid-infokey', 'givenname', 'employeenumber'] >>> attrs.attributes['displayname'] 'McCollum, Jathan' >>> o.logout(token) >>> o.is_token_valid(token) False More details Soon(TM).
About
Python interface OpenSSO/OpenAM. Implements all of the end-user authentication functionality. Admin functions coming soon...
Resources
Stars
Watchers
Forks
Packages 0
No packages published