-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
201 changed files
with
81 additions
and
31,596 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
Python OpenID may be obtained from | ||
http://www.openidenabled.com/openid/libraries/python | ||
http://github.com/openid/python-openid | ||
and we'd like to hear about how you're using this software. | ||
Write to us at openid@janrain.com. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
#!/usr/bin/env python | ||
"""Make an OpenID Assocition request against an endpoint | ||
and print the results.""" | ||
|
||
import sys | ||
|
||
from openid.store.memstore import MemoryStore | ||
from openid.consumer import consumer | ||
from openid.consumer.discover import OpenIDServiceEndpoint | ||
|
||
from datetime import datetime | ||
|
||
def verboseAssociation(assoc): | ||
"""A more verbose representation of an Association. | ||
""" | ||
d = assoc.__dict__ | ||
issued_date = datetime.fromtimestamp(assoc.issued) | ||
d['issued_iso'] = issued_date.isoformat() | ||
fmt = """ Type: %(assoc_type)s | ||
Handle: %(handle)s | ||
Issued: %(issued)s [%(issued_iso)s] | ||
Lifetime: %(lifetime)s | ||
Secret: %(secret)r | ||
""" | ||
return fmt % d | ||
|
||
def main(): | ||
if not sys.argv[1:]: | ||
print "Usage: %s ENDPOINT_URL..." % (sys.argv[0],) | ||
for endpoint_url in sys.argv[1:]: | ||
print "Associating with", endpoint_url | ||
|
||
# This makes it clear why j3h made AssociationManager when we | ||
# did the ruby port. We can't invoke requestAssociation | ||
# without these other trappings. | ||
store = MemoryStore() | ||
endpoint = OpenIDServiceEndpoint() | ||
endpoint.server_url = endpoint_url | ||
c = consumer.GenericConsumer(store) | ||
auth_req = c.begin(endpoint) | ||
if auth_req.assoc: | ||
print verboseAssociation(auth_req.assoc) | ||
else: | ||
print " ...no association." | ||
|
||
if __name__ == '__main__': | ||
main() |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,4 @@ | ||
"""Yadis. | ||
|
||
@see: U{http://www.openidenabled.com/yadis} | ||
""" | ||
|
||
__all__ = [ | ||
'constants', | ||
|
Oops, something went wrong.