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

Method compute_authenticator

scapy/layers/radius.py:1335–1342  ·  view source on GitHub ↗

Computes the authenticator field (RFC 2865 - Section 3)

(self, packed_request_auth, shared_secret)

Source from the content-addressed store, hash-verified

1333 ]
1334
1335 def compute_authenticator(self, packed_request_auth, shared_secret):
1336 """
1337 Computes the authenticator field (RFC 2865 - Section 3)
1338 """
1339
1340 data = prepare_packed_data(self, packed_request_auth)
1341 radius_mac = hashlib.md5(data + shared_secret)
1342 return radius_mac.digest()
1343
1344 def post_build(self, p, pay):
1345 p += pay

Callers 1

make_replyMethod · 0.95

Calls 2

prepare_packed_dataFunction · 0.85
digestMethod · 0.45

Tested by

no test coverage detected