This is a filesystem-based store for OpenID associations and nonces.
This store should be safe for use in concurrent systems on both windows
and unix (excluding NFS filesystems). There are a couple race conditions
in the system, but those failure cases have been set up in such a way
that the worst-case behavior is someone having to try to log in a second
time.
Most of the methods of this class are implementation details. People
wishing to just use this store need only pay attention to the __init__
method.
Methods of this object can raise OSError if unexpected filesystem
conditions, such as bad permissions or missing directories, occur.
|
__init__(self,
directory)
Initializes a new FileOpenIDStore.
|
|
readAuthKey(self)
Read the auth key from the auth key file.
|
|
createAuthKey(self)
Generate a new random auth key and safely store it in the location
specified by self.auth_key_name.
|
str
|
getAuthKey(self)
Retrieve the auth key from the file specified by
self.auth_key_name, creating it if it does not exist.
|
|
getAssociationFilename(self,
server_url,
handle)
Create a unique filename for a given server url and handle.
|
NoneType
|
storeAssociation(self,
server_url,
association)
Store an association in the association directory.
|
Association or NoneType
|
getAssociation(self,
server_url,
handle=None)
Retrieve an association.
|
bool or int
|
removeAssociation(self,
server_url,
handle)
Remove an association if it exists.
|
NoneType
|
storeNonce(self,
nonce)
Mark this nonce as present.
|
bool or int
|
useNonce(self,
nonce)
Return whether this nonce is present.
|
|
clean(self)
Remove expired entries from the database.
|
Inherited from interface.OpenIDStore :
isDumb
Inherited from object :
__delattr__ ,
__getattribute__ ,
__hash__ ,
__new__ ,
__reduce__ ,
__reduce_ex__ ,
__repr__ ,
__setattr__ ,
__str__
|