/third_party/openssl/demos/digest/ |
D | BIO_f_md.c | 46 size_t digest_size; in main() local 71 digest_size = EVP_MD_get_size(md); in main() 72 digest_value = OPENSSL_malloc(digest_size); in main() 74 … fprintf(stderr, "Can't allocate %lu bytes for the digest value.\n", (unsigned long)digest_size); in main() 101 if (BIO_gets(bio_digest, digest_value, digest_size) != digest_size) { in main() 105 for (j=0; j<digest_size; j++) { in main()
|
/third_party/fsverity-utils/programs/ |
D | cmd_digest.c | 85 ASSERT(digest->digest_size <= FS_VERITY_MAX_DIGEST_SIZE); in fsverity_cmd_digest() 92 d = xzalloc(sizeof(*d) + digest->digest_size); in fsverity_cmd_digest() 96 d->digest_size = cpu_to_le16(digest->digest_size); in fsverity_cmd_digest() 97 memcpy(d->digest, digest->digest, digest->digest_size); in fsverity_cmd_digest() 99 bin2hex((const u8 *)d, sizeof(*d) + digest->digest_size, in fsverity_cmd_digest() 102 bin2hex(digest->digest, digest->digest_size, in fsverity_cmd_digest()
|
D | cmd_measure.c | 35 d->digest_size = FS_VERITY_MAX_DIGEST_SIZE; in fsverity_cmd_measure() 47 ASSERT(d->digest_size <= FS_VERITY_MAX_DIGEST_SIZE); in fsverity_cmd_measure() 48 bin2hex(d->digest, d->digest_size, digest_hex); in fsverity_cmd_measure()
|
D | test_compute_digest.c | 177 for (i = 0; i < d->digest_size; i++) { in fix_digest_and_print() 183 if (i + 1 == d->digest_size) in fix_digest_and_print() 378 ASSERT(d->digest_size == SHA256_DIGEST_LENGTH); in test_metadata_callbacks() 423 ASSERT(d->digest_size == in main() 429 d->digest_size)); in main()
|
D | cmd_sign.c | 137 ASSERT(digest->digest_size <= FS_VERITY_MAX_DIGEST_SIZE); in fsverity_cmd_sign() 138 bin2hex(digest->digest, digest->digest_size, digest_hex); in fsverity_cmd_sign()
|
D | test_sign_digest.c | 35 d->digest_size = SHA256_DIGEST_SIZE; in main()
|
/third_party/python/Lib/test/ |
D | test_hmac.py | 43 self, h, digest, hashname, digest_size, block_size argument 48 self.assertEqual(h.digest_size, digest_size) 52 self, key, data, digest, hashfunc, hashname, digest_size, block_size argument 56 h, digest, hashname, digest_size, block_size 61 h, digest, hashname, digest_size, block_size 72 h, digest, hashname, digest_size, block_size 98 h, digest, hashname, digest_size, block_size 104 h, digest, hashname, digest_size, block_size 116 h, digest, hashname, digest_size, block_size 122 h, digest, hashname, digest_size, block_size [all …]
|
D | test_hashlib.py | 365 self.assertEqual(len(digest), m.digest_size) 394 def check_blocksize_name(self, name, block_size=0, digest_size=0, argument 400 self.assertEqual(m.digest_size, digest_size) 407 self.assertEqual(len(m.digest()), digest_size) 408 self.assertEqual(len(m.hexdigest()), 2*digest_size) 601 digest_size, max_offset): argument 614 self.assertEqual(constructor.MAX_DIGEST_SIZE, digest_size) 615 for i in range(1, digest_size + 1): 616 constructor(digest_size=i) 617 self.assertRaises(ValueError, constructor, digest_size=-1) [all …]
|
D | time_hashlib.py | 87 test_scaled_msg(scale=creatorFunc().digest_size, name='[digest_size data]')
|
/third_party/fsverity-utils/lib/ |
D | compute_digest.c | 41 next->filled += hash->alg->digest_size; in hash_one_block() 49 return block->filled + hash->alg->digest_size > block_size; in block_is_full() 109 const u32 hashes_per_block = block_size / hash->alg->digest_size; in compute_root_hash() 123 memset(root_hash, 0, hash->alg->digest_size); in compute_root_hash() 222 if (WARN_ON(buffers[num_levels].filled != hash->alg->digest_size)) { in compute_root_hash() 288 if (block_size < 2 * hash_alg->digest_size) { in libfsverity_compute_digest() 319 digest = libfsverity_zalloc(sizeof(*digest) + hash_alg->digest_size); in libfsverity_compute_digest() 325 digest->digest_size = hash_alg->digest_size; in libfsverity_compute_digest()
|
D | sign_digest.c | 427 if (!hash_alg || digest->digest_size != hash_alg->digest_size) { in libfsverity_sign_digest() 449 d = libfsverity_zalloc(sizeof(*d) + digest->digest_size); in libfsverity_sign_digest() 456 d->digest_size = cpu_to_le16(digest->digest_size); in libfsverity_sign_digest() 457 memcpy(d->digest, digest->digest, digest->digest_size); in libfsverity_sign_digest() 459 err = sign_pkcs7(d, sizeof(*d) + digest->digest_size, in libfsverity_sign_digest()
|
D | hash_algs.c | 93 if (WARN_ON(EVP_MD_size(md) != alg->digest_size)) in openssl_digest_ctx_create() 153 .digest_size = 32, 159 .digest_size = 64, 196 return alg ? alg->digest_size : -1; in libfsverity_get_digest_size()
|
D | lib_private.h | 32 unsigned int digest_size; member
|
/third_party/python/Lib/ |
D | hmac.py | 24 digest_size = None variable 68 self.digest_size = self._hmac.digest_size 82 self.digest_size = self._inner.digest_size 129 other.digest_size = self.digest_size
|
D | hashlib.py | 230 dklen = outer.digest_size 246 dkey += rkey.to_bytes(inner.digest_size, 'big')
|
/third_party/python/Modules/_blake2/clinic/ |
D | blake2b_impl.c.h | 15 py_blake2b_new_impl(PyTypeObject *type, PyObject *data, int digest_size, 32 int digest_size = BLAKE2B_OUTBYTES; in py_blake2b_new() local 59 digest_size = _PyLong_AsInt(fastargs[1]); in py_blake2b_new() 60 if (digest_size == -1 && PyErr_Occurred()) { in py_blake2b_new() 169 …return_value = py_blake2b_new_impl(type, data, digest_size, &key, &salt, &person, fanout, depth, l… in py_blake2b_new()
|
D | blake2s_impl.c.h | 15 py_blake2s_new_impl(PyTypeObject *type, PyObject *data, int digest_size, 32 int digest_size = BLAKE2S_OUTBYTES; in py_blake2s_new() local 59 digest_size = _PyLong_AsInt(fastargs[1]); in py_blake2s_new() 60 if (digest_size == -1 && PyErr_Occurred()) { in py_blake2s_new() 169 …return_value = py_blake2s_new_impl(type, data, digest_size, &key, &salt, &person, fanout, depth, l… in py_blake2s_new()
|
/third_party/python/Modules/ |
D | _hashopenssl.c | 510 unsigned int digest_size; in EVP_digest_impl() local 521 digest_size = EVP_MD_CTX_size(temp_ctx); in EVP_digest_impl() 527 retval = PyBytes_FromStringAndSize((const char *)digest, digest_size); in EVP_digest_impl() 544 unsigned int digest_size; in EVP_hexdigest_impl() local 556 digest_size = EVP_MD_CTX_size(temp_ctx); in EVP_hexdigest_impl() 564 return _Py_strhex((const char *)digest, (Py_ssize_t)digest_size); in EVP_hexdigest_impl() 1570 unsigned int digest_size = EVP_MD_size(HMAC_CTX_get_md(self->ctx)); in _hmac_digest_size() local 1571 assert(digest_size <= EVP_MAX_MD_SIZE); in _hmac_digest_size() 1572 return digest_size; in _hmac_digest_size() 1713 unsigned int digest_size = _hmac_digest_size(self); in _hashlib_HMAC_digest_impl() local [all …]
|
/third_party/fsverity-utils/common/ |
D | fsverity_uapi.h | 35 __u16 digest_size; /* input/output */ member 84 __le16 digest_size; member
|
/third_party/python/Doc/library/ |
D | hashlib.rst | 103 >>> m.digest_size 153 .. data:: hash.digest_size 192 This is a bytes object of size :attr:`digest_size` which may contain bytes in 324 .. function:: blake2b(data=b'', *, digest_size=64, key=b'', salt=b'', \ 329 .. function:: blake2s(data=b'', *, digest_size=32, key=b'', salt=b'', \ 341 * *digest_size*: size of output digest in bytes. 355 Hash digest_size len(key) len(salt) len(person) 474 >>> h = blake2b(digest_size=20) 478 >>> h.digest_size 488 >>> blake2b(digest_size=10).hexdigest() [all …]
|
/third_party/python/Modules/_blake2/ |
D | blake2b_impl.c | 89 py_blake2b_new_impl(PyTypeObject *type, PyObject *data, int digest_size, in py_blake2b_new_impl() argument 108 if (digest_size <= 0 || digest_size > BLAKE2B_OUTBYTES) { in py_blake2b_new_impl() 114 self->param.digest_length = digest_size; in py_blake2b_new_impl()
|
D | blake2s_impl.c | 88 py_blake2s_new_impl(PyTypeObject *type, PyObject *data, int digest_size, in py_blake2s_new_impl() argument 107 if (digest_size <= 0 || digest_size > BLAKE2S_OUTBYTES) { in py_blake2s_new_impl() 113 self->param.digest_length = digest_size; in py_blake2s_new_impl()
|
/third_party/node/src/crypto/ |
D | crypto_hash.cc | 334 unsigned int digest_size; in InternalVerifyIntegrity() local 338 &digest_size, in InternalVerifyIntegrity() 345 if (digest_size != expected.size() || in InternalVerifyIntegrity() 346 CRYPTO_memcmp(digest, expected.data(), digest_size) != 0) { in InternalVerifyIntegrity() 351 digest_size, in InternalVerifyIntegrity()
|
/third_party/node/deps/ngtcp2/ngtcp2/crypto/picotls/ |
D | picotls.c | 150 return md->digest_size; in crypto_md_hashlen() 288 prk = ptls_iovec_init(prkbuf, algo->digest_size); in ngtcp2_crypto_hkdf() 566 size_t secretlen = cipher->hash->digest_size; in update_traffic_key_server_cb() 611 size_t secretlen = cipher->hash->digest_size; in update_traffic_key_cb()
|
/third_party/fsverity-utils/include/ |
D | libfsverity.h | 80 uint16_t digest_size; /* digest size in bytes */ member
|