pyxmpp.streamsasl.StreamSASLMixIn

Package pyxmpp :: Module streamsasl :: Class StreamSASLMixIn |
[show private | hide private]
[frames | no frames]

## Class StreamSASLMixIn

    PasswordManager --+
                      |
                     StreamSASLMixIn

Known Subclasses:
  `Stream`

SASL authentication mix-in class for XMPP stream.

Method Summary
| ``__init__`(self, sasl_mechanisms)` Initialize Stream object
Inherited from PasswordManager
`bool` | ``check_authzid`(self, authzid, extra_info)` Check if the authenticated entity is allowed to use given authorization id.
`bool` | ``check_password`(self, username, password, realm)` Check the password validity.
`unicode` | ``choose_realm`(self, realm_list)` Choose an authentication realm from the list provided by the server.
`str` | ``generate_nonce`(self)` Generate a random string for digest authentication challenges.
`unicode`,`str` tuple. | ``get_password`(self, username, realm, acceptable_formats)` Get the password for user authentication.
`list` of `unicode` | ``get_realms`(self)` Get available realms list.
| ``get_serv_host`(self)` Return the host name for DIGEST-MD5 'digest-uri' field.
| ``get_serv_name`(self)` Return the service name for DIGEST-MD5 'digest-uri' field.
| ``get_serv_type`(self)` Return the service type for DIGEST-MD5 'digest-uri' field.

Method Details

### __init__(self, sasl_mechanisms=()) (Constructor) Initialize Stream object Parameters: `sasl_mechanisms` - sequence of SASL mechanisms allowed for authentication. Currently "PLAIN" and "DIGEST-MD5" are supported. Overrides: `pyxmpp.sasl.core.PasswordManager.__init__`