MCPcopy Index your code
hub / github.com/python/cpython / block_builtin_algorithms

Function block_builtin_algorithms

Lib/test/support/hashlib_helper.py:1090–1095  ·  view source on GitHub ↗

Block HACL* implementations, except those given in *exclude*.

(*, exclude=())

Source from the content-addressed store, hash-verified

1088
1089@contextlib.contextmanager
1090def block_builtin_algorithms(*, exclude=()):
1091 """Block HACL* implementations, except those given in *exclude*."""
1092 with contextlib.ExitStack() as stack:
1093 for name in CANONICAL_DIGEST_NAMES.difference(exclude):
1094 stack.enter_context(block_algorithm(name, allow_openssl=True))
1095 yield

Callers

nothing calls this directly

Calls 3

block_algorithmFunction · 0.85
differenceMethod · 0.80
enter_contextMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…