/external/python/cpython2/Lib/ |
D | hmac.py | 30 def __init__(self, key, msg = None, digestmod = None): argument 43 if digestmod is None: 45 digestmod = hashlib.md5 47 if hasattr(digestmod, '__call__'): 48 self.digest_cons = digestmod 50 self.digest_cons = lambda d='': digestmod.new(d) 125 def new(key, msg = None, digestmod = None): argument 136 return HMAC(key, msg, digestmod)
|
/external/python/cpython3/Lib/ |
D | hmac.py | 38 def __init__(self, key, msg=None, digestmod=''): argument 55 if not digestmod: 58 if callable(digestmod): 59 self._digest_cons = digestmod 60 elif isinstance(digestmod, str): 61 self._digest_cons = lambda d=b'': _hashlib.new(digestmod, d) 63 self._digest_cons = lambda d=b'': digestmod.new(d) 153 def new(key, msg=None, digestmod=''): argument 170 return HMAC(key, msg, digestmod)
|
/external/python/cpython3/Lib/test/ |
D | test_hmac.py | 38 h = hmac.HMAC(key, data, digestmod=hashfunc) 45 h = hmac.HMAC(key, data, digestmod=hashname) 52 h = hmac.HMAC(key, digestmod=hashname) 58 h = hmac.new(key, data, digestmod=hashname) 65 h = hmac.new(key, None, digestmod=hashname) 69 h = hmac.new(key, digestmod=hashname) 73 h = hmac.new(key, data, digestmod=hashfunc) 95 h = c_hmac_new(key, data, digestmod=hashname) 102 h = c_hmac_new(key, digestmod=hashname) 340 hmac.HMAC(b'a', b'b', digestmod=MockCrazyHash) [all …]
|
/external/scapy/scapy/layers/ |
D | ipsec.py | 484 def __init__(self, name, mac, digestmod, icv_size, key_size=None): argument 496 self.digestmod = digestmod 517 return self.mac(self.digestmod(key), default_backend()) 519 return self.mac(key, self.digestmod(), default_backend()) 589 'NULL': AuthAlgo('NULL', mac=None, digestmod=None, icv_size=0), 596 digestmod=hashes.SHA1, 600 digestmod=hashes.SHA256, 604 digestmod=hashes.SHA384, 608 digestmod=hashes.SHA512, 613 digestmod=hashes.MD5, [all …]
|
/external/python/cpython3/Doc/library/ |
D | hmac.rst | 17 .. function:: new(key, msg=None, digestmod='') 21 *digestmod* is the digest name, digest constructor or module for the HMAC 28 Parameter *digestmod* can be the name of a hash algorithm. 31 MD5 as implicit default digest for *digestmod* is deprecated. 32 The digestmod parameter is now required. Pass it as a keyword
|
D | hashlib.rst | 544 >>> m = hmac.new(b'secret key', digestmod=hashlib.blake2s)
|
/external/python/cpython2/Lib/test/ |
D | test_hmac.py | 49 h = hmac.HMAC(key, data, digestmod=hashlib.sha1) 83 h = hmac.HMAC(key, data, digestmod=hashfunc) 219 hmac.HMAC('a', 'b', digestmod=MockCrazyHash) 224 hmac.HMAC('a', 'b', digestmod=MockCrazyHash)
|
/external/python/cpython2/Doc/library/ |
D | hmac.rst | 19 .. function:: new(key[, msg[, digestmod]]) 22 is made. *digestmod* is the digest constructor or module for the HMAC object to
|
/external/scapy/scapy/contrib/ |
D | carp.py | 59 h = hmac.new(pw, digestmod = hashlib.sha1)
|
/external/python/cpython3/Modules/clinic/ |
D | _hashopenssl.c.h | 1179 const char *digestmod); 1191 const char *digestmod = NULL; in _hashlib_hmac_new() local 1218 digestmod = PyUnicode_AsUTF8AndSize(args[2], &digestmod_length); in _hashlib_hmac_new() 1219 if (digestmod == NULL) { in _hashlib_hmac_new() 1222 if (strlen(digestmod) != (size_t)digestmod_length) { in _hashlib_hmac_new() 1227 return_value = _hashlib_hmac_new_impl(module, &key, msg_obj, digestmod); in _hashlib_hmac_new()
|
/external/python/cpython3/Modules/ |
D | _hashopenssl.c | 1395 const char *digestmod) in _hashlib_hmac_new_impl() argument 1410 if ((digestmod == NULL) || !strlen(digestmod)) { in _hashlib_hmac_new_impl() 1416 digest = py_digest_by_name(digestmod); in _hashlib_hmac_new_impl()
|
/external/python/cpython3/Doc/whatsnew/ |
D | 3.4.rst | 925 The *digestmod* argument to the :func:`hmac.new` function may now be any hash 927 which the value of *digestmod* defaults to ``MD5`` is deprecated: in a 2110 * ``MD5`` as the default *digestmod* for the :func:`hmac.new` function is 2112 *digestmod* argument. 2446 * Since the *digestmod* argument to the :func:`hmac.new` function will in the 2448 explicitly specify a *digestmod* (:issue:`17276`).
|
/external/python/cpython3/Misc/NEWS.d/ |
D | 3.9.0a1.rst | 1308 when the digestmod parameter, now required in 3.8, is omitted. Also
|
/external/python/cpython3/Misc/ |
D | HISTORY | 3362 - Issue #17276: MD5 as default digestmod for HMAC is deprecated. The HMAC 3363 module supports digestmod names, e.g. hmac.HMAC('sha1').
|