MCPcopy Create free account
hub / github.com/secdev/scapy / digest

Method digest

scapy/layers/tls/crypto/h_mac.py:61–65  ·  view source on GitHub ↗
(self, tbd)

Source from the content-addressed store, hash-verified

59 self.key = bytes_encode(key)
60
61 def digest(self, tbd):
62 if self.key is None:
63 raise HMACError
64 tbd = bytes_encode(tbd)
65 return hmac.new(self.key, tbd, self.hash_alg.hash_cls).digest()
66
67 def digest_sslv3(self, tbd):
68 if self.key is None:

Callers

nothing calls this directly

Calls 3

bytes_encodeFunction · 0.90
newMethod · 0.80
digestMethod · 0.45

Tested by

no test coverage detected