Home
last modified time | relevance | path

Searched refs:resultlen (Results 1 – 17 of 17) sorted by relevance

/openbmc/qemu/tests/unit/
H A Dtest-crypto-hash.c111 size_t resultlen = 0; in test_hash_alloc() local
123 &resultlen, in test_hash_alloc()
126 g_assert(resultlen == expected_lens[i]); in test_hash_alloc()
128 for (j = 0; j < resultlen; j++) { in test_hash_alloc()
143 size_t resultlen; in test_hash_prealloc() local
151 resultlen = expected_lens[i]; in test_hash_prealloc()
152 origresult = result = g_new0(uint8_t, resultlen); in test_hash_prealloc()
158 &resultlen, in test_hash_prealloc()
163 g_assert(resultlen == expected_lens[i]); in test_hash_prealloc()
164 for (j = 0; j < resultlen; j++) { in test_hash_prealloc()
[all …]
H A Dtest-crypto-hmac.c99 size_t resultlen = 0; in test_hmac_alloc() local
116 &resultlen, &error_fatal); in test_hmac_alloc()
119 for (j = 0; j < resultlen; j++) { in test_hmac_alloc()
138 size_t resultlen = 0; in test_hmac_prealloc() local
149 resultlen = strlen(exp_output) / 2; in test_hmac_prealloc()
150 origresult = result = g_new0(uint8_t, resultlen); in test_hmac_prealloc()
158 &resultlen, &error_fatal); in test_hmac_prealloc()
164 for (j = 0; j < resultlen; j++) { in test_hmac_prealloc()
183 size_t resultlen = 0; in test_hmac_iov() local
204 &resultlen, &error_fatal); in test_hmac_iov()
[all …]
/openbmc/qemu/crypto/
H A Dhmac.c22 size_t *resultlen, in qcrypto_hmac_bytesv() argument
27 return drv->hmac_bytesv(hmac, iov, niov, result, resultlen, errp); in qcrypto_hmac_bytesv()
34 size_t *resultlen, in qcrypto_hmac_bytes() argument
42 return qcrypto_hmac_bytesv(hmac, &iov, 1, result, resultlen, errp); in qcrypto_hmac_bytes()
52 size_t resultlen = 0; in qcrypto_hmac_digestv() local
55 if (qcrypto_hmac_bytesv(hmac, iov, niov, &result, &resultlen, errp) < 0) { in qcrypto_hmac_digestv()
59 *digest = g_new0(char, (resultlen * 2) + 1); in qcrypto_hmac_digestv()
61 for (i = 0 ; i < resultlen ; i++) { in qcrypto_hmac_digestv()
66 (*digest)[resultlen * 2] = '\0'; in qcrypto_hmac_digestv()
H A Dhash.c51 size_t *resultlen, in qcrypto_hash_bytesv() argument
61 qcrypto_hash_finalize_bytes(ctx, result, resultlen, errp) < 0) { in qcrypto_hash_bytesv()
73 size_t *resultlen, in qcrypto_hash_bytes() argument
78 return qcrypto_hash_bytesv(alg, &iov, 1, result, resultlen, errp); in qcrypto_hash_bytes()
156 size_t resultlen = 0; in qcrypto_hash_finalize_digest() local
159 ret = qcrypto_hash_finalize_bytes(hash, &result, &resultlen, errp); in qcrypto_hash_finalize_digest()
161 *digest = g_new0(char, (resultlen * 2) + 1); in qcrypto_hash_finalize_digest()
162 for (i = 0 ; i < resultlen ; i++) { in qcrypto_hash_finalize_digest()
166 (*digest)[resultlen * 2] = '\0'; in qcrypto_hash_finalize_digest()
178 size_t resultlen = 0; in qcrypto_hash_finalize_base64() local
[all …]
H A Dhmac-glib.c89 size_t *resultlen, in qcrypto_glib_hmac_bytesv() argument
107 if (*resultlen == 0) { in qcrypto_glib_hmac_bytesv()
108 *resultlen = ret; in qcrypto_glib_hmac_bytesv()
109 *result = g_new0(uint8_t, *resultlen); in qcrypto_glib_hmac_bytesv()
110 } else if (*resultlen != ret) { in qcrypto_glib_hmac_bytesv()
112 *resultlen, ret); in qcrypto_glib_hmac_bytesv()
116 g_hmac_get_digest(ctx->ghmac, *result, resultlen); in qcrypto_glib_hmac_bytesv()
H A Dhmac-gcrypt.c103 size_t *resultlen, in qcrypto_gcrypt_hmac_bytesv() argument
124 if (*resultlen == 0) { in qcrypto_gcrypt_hmac_bytesv()
125 *resultlen = ret; in qcrypto_gcrypt_hmac_bytesv()
126 *result = g_new0(uint8_t, *resultlen); in qcrypto_gcrypt_hmac_bytesv()
127 } else if (*resultlen != ret) { in qcrypto_gcrypt_hmac_bytesv()
129 *resultlen, ret); in qcrypto_gcrypt_hmac_bytesv()
133 err = gcry_mac_read(ctx->handle, *result, resultlen); in qcrypto_gcrypt_hmac_bytesv()
H A Dhmac-gnutls.c102 size_t *resultlen, in qcrypto_gnutls_hmac_bytesv() argument
122 if (*resultlen == 0) { in qcrypto_gnutls_hmac_bytesv()
123 *resultlen = ret; in qcrypto_gnutls_hmac_bytesv()
124 *result = g_new0(uint8_t, *resultlen); in qcrypto_gnutls_hmac_bytesv()
125 } else if (*resultlen != ret) { in qcrypto_gnutls_hmac_bytesv()
127 *resultlen, ret); in qcrypto_gnutls_hmac_bytesv()
H A Dhmac-nettle.c148 size_t *resultlen, in qcrypto_nettle_hmac_bytesv() argument
167 if (*resultlen == 0) { in qcrypto_nettle_hmac_bytesv()
168 *resultlen = qcrypto_hmac_alg_map[hmac->alg].len; in qcrypto_nettle_hmac_bytesv()
169 *result = g_new0(uint8_t, *resultlen); in qcrypto_nettle_hmac_bytesv()
170 } else if (*resultlen != qcrypto_hmac_alg_map[hmac->alg].len) { in qcrypto_nettle_hmac_bytesv()
173 *resultlen, qcrypto_hmac_alg_map[hmac->alg].len); in qcrypto_nettle_hmac_bytesv()
177 qcrypto_hmac_alg_map[hmac->alg].digest(&ctx->u, *resultlen, *result); in qcrypto_nettle_hmac_bytesv()
H A Dx509-utils.c31 size_t *resultlen, in qcrypto_get_x509_cert_fingerprint() argument
57 if (*resultlen < hlen) { in qcrypto_get_x509_cert_fingerprint()
60 *resultlen, hlen); in qcrypto_get_x509_cert_fingerprint()
66 result, resultlen) != 0) { in qcrypto_get_x509_cert_fingerprint()
H A Dhash-afalg.c244 size_t *resultlen, in qcrypto_afalg_hash_hmac_bytesv() argument
252 resultlen, errp); in qcrypto_afalg_hash_hmac_bytesv()
262 size_t *resultlen, in qcrypto_afalg_hmac_bytesv() argument
266 iov, niov, result, resultlen, in qcrypto_afalg_hmac_bytesv()
H A Dhashpriv.h31 size_t *resultlen,
H A Dhmacpriv.h25 size_t *resultlen,
/openbmc/u-boot/cmd/
H A Dfdc.c36 uchar resultlen; /* lenght of result */ member
279 pCMD->resultlen=0; /* result only after execution */ in fdc_issue_cmd()
283 pCMD->resultlen=0; /* no result */ in fdc_issue_cmd()
290 pCMD->resultlen=0; /* no result */ in fdc_issue_cmd()
298 pCMD->resultlen=0; /* no result */ in fdc_issue_cmd()
302 pCMD->resultlen=10; /* 10 byte result */ in fdc_issue_cmd()
307 pCMD->resultlen=7; /* 7 byte result */ in fdc_issue_cmd()
312 pCMD->resultlen=0; /* no result */ in fdc_issue_cmd()
317 pCMD->resultlen=2; in fdc_issue_cmd()
328 for(i=0;i<pCMD->resultlen;i++) { in fdc_issue_cmd()
/openbmc/qemu/include/crypto/
H A Dhmac.h100 size_t *resultlen,
133 size_t *resultlen,
H A Dhash.h96 size_t *resultlen,
128 size_t *resultlen,
H A Dx509-utils.h19 size_t *resultlen,
/openbmc/linux/crypto/
H A Daf_alg.c1146 unsigned int resultlen; in af_alg_async_cb() local
1149 resultlen = areq->outlen; in af_alg_async_cb()
1154 iocb->ki_complete(iocb, err ? err : (int)resultlen); in af_alg_async_cb()