Home | Trees | Indices | Help |
---|
|
object --+ | interface.OpenIDStore --+ | FileOpenIDStore
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.
|
|||
|
|||
|
|||
|
|||
|
|||
NoneType
|
|
||
Association or NoneType
|
|
||
|
|||
bool or int
|
|
||
bool
|
|
||
|
|||
|
|||
int |
|
||
int |
|
||
Inherited from |
|
|||
Inherited from |
|
Initializes a new FileOpenIDStore. This initializes the nonce and association directories, which are subdirectories of the directory passed in.
|
Make sure that the directories in which we store our data exist. () -> NoneType |
Create a temporary file on the same filesystem as self.association_dir. The temporary directory should not be cleaned if there are any processes using the store. If there is no active process using the store, it is safe to remove all of the files in the temporary directory. () -> (file, str) |
Create a unique filename for a given server url and handle. This implementation does not assume anything about the format of the handle. The filename that is returned will contain the domain name from the server URL for ease of human inspection of the data directory. (str, str) -> str |
Store an association in the association directory. (str, Association) -> NoneType
|
Retrieve an association. If no handle is specified, return the association with the latest expiration. (str, str or NoneType) -> Association or NoneType
|
Remove an association if it exists. Do nothing if it does not. (str, str) -> bool
|
Return whether this nonce is valid. str -> bool
|
Remove expired entries from the database. This is potentially expensive, so only run when it is acceptable to take time. () -> NoneType
|
Remove expired associations from the store. This method is not called in the normal operation of the library. It provides a way for store admins to keep their storage from filling up with expired data.
|
Remove expired nonces from the store. Discards any nonce from storage that is old enough that its timestamp would not pass useNonce. This method is not called in the normal operation of the library. It provides a way for store admins to keep their storage from filling up with expired data.
|
Home | Trees | Indices | Help |
---|
Generated by Epydoc 3.0.1 on Fri Oct 31 11:37:50 2014 | http://epydoc.sourceforge.net |