tlslite.utils.hmac

Package tlslite :: Package utils :: Module hmac |
[show private | hide private]
[frames | no frames]

## Module tlslite.utils.hmac

HMAC (Keyed-Hashing for Message Authentication) Python module.

Implements the HMAC algorithm as described by RFC 2104.

(This file is modified from the standard library version to do faster copying)

Classes
`HMAC` | RFC2104 HMAC class.

Function Summary
| ``new`(key, msg, digestmod)` Create a new hashing object and return it.
| ``_strxor`(s1, s2)` Utility method.

Variable Summary
`NoneType` | `digest_size` = None

Function Details

### new(key, msg=None, digestmod=None) Create a new hashing object and return it. key: The starting key for the hash. msg: if available, will immediately be hashed into the object's starting state. You can now feed arbitrary strings into the object using its update() method, and can ask for the hash value at any time by calling its digest() method.

### _strxor(s1, s2) Utility method. XOR the two strings s1 and s2 (must have same length).

Variable Details

    ### digest_size Type: `NoneType` Value:
        None

Generated by Epydoc 2.0 on Mon Feb 21 21:56:56 2005 | http://epydoc.sf.net