[ class tree: OpenID ] [ index: OpenID ] [ all elements ]

Class: Auth_OpenID_DumbStore

Source Location: /zp-extensions/federated_logon/Auth/OpenID/DumbStore.php

Class Auth_OpenID_DumbStore

Class Overview

This is a store for use in the worst case, when you have no way of saving state on the consumer site. Using this store makes the consumer vulnerable to replay attacks, as it's unable to use nonces. Avoid using this store if it is at all possible.

Most of the methods of this class are implementation details. Users of this class need to worry only about the constructor.

Located in /zp-extensions/federated_logon/Auth/OpenID/DumbStore.php [line 34]

Auth_OpenID_OpenIDStore
   |
   --Auth_OpenID_DumbStore
Author(s): Information Tags:

Methods

[ Top ]
Inherited Properties, Constants, and Methods
Inherited Properties Inherited Methods Inherited Constants

Inherited From Auth_OpenID_OpenIDStore

Auth_OpenID_OpenIDStore::cleanup()
Auth_OpenID_OpenIDStore::cleanupAssociations()
Auth_OpenID_OpenIDStore::cleanupNonces()
Auth_OpenID_OpenIDStore::getAssociation()
This method returns an Association object from storage that matches the server URL and, if specified, handle. It returns null if no such association is found or if the matching association is expired.
Auth_OpenID_OpenIDStore::removeAssociation()
This method removes the matching association if it's found, and returns whether the association was removed or not.
Auth_OpenID_OpenIDStore::reset()
Removes all entries from the store; implementation is optional.
Auth_OpenID_OpenIDStore::storeAssociation()
This method puts an Association object into storage, retrievable by server URL and handle.
Auth_OpenID_OpenIDStore::supportsCleanup()
Report whether this storage supports cleanup
Auth_OpenID_OpenIDStore::useNonce()
Called when using a nonce.

[ Top ]
Method Summary
Auth_OpenID_DumbStore   Auth_OpenID_DumbStore()   Creates a new Auth_OpenID_DumbStore instance. For the security of the tokens generated by the library, this class attempts to at least have a secure implementation of getAuthKey.
void   getAssociation()   This implementation always returns null.
void   getAuthKey()   This method returns the auth key generated by the constructor.
void   removeAssociation()   This implementation always returns false.
void   storeAssociation()   This implementation does nothing.
void   useNonce()   In a system truly limited to dumb mode, nonces must all be accepted. This therefore always returns true, which makes replay attacks feasible.

[ Top ]
Methods
Constructor Auth_OpenID_DumbStore  [line 53]

  Auth_OpenID_DumbStore Auth_OpenID_DumbStore( string $secret_phrase  )

Creates a new Auth_OpenID_DumbStore instance. For the security of the tokens generated by the library, this class attempts to at least have a secure implementation of getAuthKey.

When you create an instance of this class, pass in a secret phrase. The phrase is hashed with sha1 to make it the correct length and form for an auth key. That allows you to use a long string as the secret phrase, which means you can make it very difficult to guess.

Each Auth_OpenID_DumbStore instance that is created for use by your consumer site needs to use the same $secret_phrase.

Parameters:
string   $secret_phrase:  secret_phrase The phrase used to create the auth key returned by getAuthKey


[ Top ]
getAssociation  [line 68]

  void getAssociation( $server_url, [ $handle = null]  )

This implementation always returns null.

Parameters:
   $server_url: 
   $handle: 


Redefinition of:
Auth_OpenID_OpenIDStore::getAssociation()
This method returns an Association object from storage that matches the server URL and, if specified, handle. It returns null if no such association is found or if the matching association is expired.

[ Top ]
getAuthKey  [line 94]

  void getAuthKey( )

This method returns the auth key generated by the constructor.



[ Top ]
removeAssociation  [line 76]

  void removeAssociation( $server_url, $handle  )

This implementation always returns false.

Parameters:
   $server_url: 
   $handle: 


Redefinition of:
Auth_OpenID_OpenIDStore::removeAssociation()
This method removes the matching association if it's found, and returns whether the association was removed or not.

[ Top ]
storeAssociation  [line 61]

  void storeAssociation( $server_url, $association  )

This implementation does nothing.

Parameters:
   $server_url: 
   $association: 


Redefinition of:
Auth_OpenID_OpenIDStore::storeAssociation()
This method puts an Association object into storage, retrievable by server URL and handle.

[ Top ]
useNonce  [line 86]

  void useNonce( $server_url, $timestamp, $salt  )

In a system truly limited to dumb mode, nonces must all be accepted. This therefore always returns true, which makes replay attacks feasible.

Parameters:
   $server_url: 
   $timestamp: 
   $salt: 


Redefinition of:
Auth_OpenID_OpenIDStore::useNonce()
Called when using a nonce.

[ Top ]

Documentation generated on Tue, 20 Dec 2011 16:07:10 +0100 by phpDocumentor 1.4.3