Package openid :: Package extensions :: Module ax
[hide private]
[frames] | no frames]

Module ax

source code

Implements the OpenID Attribute Exchange specification, version 1.0.


Since: 2.1.0

Classes [hide private]
  AXError
Results from data that does not meet the attribute exchange 1.0 specification
  NotAXMessage
Raised when there is no Attribute Exchange mode in the message.
  AXMessage
Abstract class containing common code for attribute exchange messages
  AttrInfo
Represents a single attribute in an attribute exchange request.
  FetchRequest
An attribute exchange 'fetch_request' message.
  AXKeyValueMessage
An abstract class that implements a message that has attribute keys and values.
  FetchResponse
A fetch_response attribute exchange message
  StoreRequest
A store request attribute exchange message representation
  StoreResponse
An indication that the store request was processed along with this OpenID transaction.
Functions [hide private]
 
checkAlias(alias)
Check an alias for invalid characters; raise AXError if any are found.
source code
 
toTypeURIs(namespace_map, alias_list_s)
Given a namespace mapping and a string containing a comma-separated list of namespace aliases, return a list of type URIs that correspond to those aliases.
source code
Variables [hide private]
  UNLIMITED_VALUES = 'unlimited'
  MINIMUM_SUPPORTED_ALIAS_LENGTH = 32
  __package__ = 'openid.extensions'
Function Details [hide private]

checkAlias(alias)

source code 

Check an alias for invalid characters; raise AXError if any are found. Return None if the alias is valid.

toTypeURIs(namespace_map, alias_list_s)

source code 

Given a namespace mapping and a string containing a comma-separated list of namespace aliases, return a list of type URIs that correspond to those aliases.

Parameters:
  • namespace_map (openid.message.NamespaceMap) - The mapping from namespace URI to alias
  • alias_list_s (str or NoneType) - The string containing the comma-separated list of aliases. May also be None for convenience.
Returns:
The list of namespace URIs that corresponds to the supplied list of aliases. If the string was zero-length or None, an empty list will be returned.
Raises:
  • KeyError - If an alias is present in the list of aliases but is not present in the namespace map.