module documentation
Utility functions for hashing.
| Function | |
Compute fingerprints for a list of files. |
| Function | |
Calculates the HMAC-SHA1 digest of a message. |
| Function | |
Verifies the HMAC-SHA1 digest of a text. |
| Function | _ |
Compute the fingerprint of a file. |
Compute fingerprints for a list of files.
| Parameters | |
| files:list | the list of filename to fingerprint |
| Returns | |
| dict | a dictionary filename: fingerprint, holding only existing files |
Calculates the HMAC-SHA1 digest of a message.
HMAC is defined in RFC2104.
| Parameters | |
| key:string | Secret key |
| msg:string or bytes | Undocumented |
| salt | Undocumented |
Verifies the HMAC-SHA1 digest of a text.
HMAC is defined in RFC2104.
| Parameters | |
| key:string | Secret key |
| text:string | Undocumented |
| digest:string | Expected digest |
| salt | Undocumented |
| Returns | |
| bool | Whether HMAC-SHA1 digest matches |