MCPcopy Create free account
hub / github.com/celery/celery / get_digest_algorithm

Function get_digest_algorithm

celery/security/utils.py:13–16  ·  view source on GitHub ↗

Convert string to hash object of cryptography library.

(digest='sha256')

Source from the content-addressed store, hash-verified

11
12
13def get_digest_algorithm(digest='sha256'):
14 """Convert string to hash object of cryptography library."""
15 assert digest is not None
16 return getattr(hashes, digest.upper())()
17
18
19@contextmanager

Callers 3

test_signMethod · 0.90
__init__Method · 0.85

Calls

no outgoing calls

Tested by 2

test_signMethod · 0.72