Lines Matching refs:_hashlib
48 from _hashlib import HASH, HASHXOF, openssl_md_meth_names
141 _hashlib = self._conditional_import_module('_hashlib')
142 self._hashlib = _hashlib
143 if _hashlib:
146 self.assertTrue(hasattr(_hashlib, 'openssl_md5'))
147 self.assertTrue(hasattr(_hashlib, 'openssl_sha1'))
149 constructor = getattr(_hashlib, 'openssl_'+algorithm, None)
199 if hasattr(self._hashlib, "get_fips_mode"):
200 return self._hashlib.get_fips_mode()
231 if self._hashlib is not None:
232 self._hashlib.new("md5", usedforsecurity=True)
233 self._hashlib.openssl_md5(usedforsecurity=True)
242 if self._hashlib is not None:
243 self._hashlib.new("md5", usedforsecurity=False)
244 self._hashlib.openssl_md5(usedforsecurity=False)