/external/tpm2/ |
D | HMAC_Start.c | 28 TPM_ALG_ID hashAlg; in TPM2_HMAC_Start() local 51 hashAlg = in->hashAlg; in TPM2_HMAC_Start() 55 hashAlg in TPM2_HMAC_Start() 56 = publicArea->parameters.keyedHashDetail.scheme.details.hmac.hashAlg; in TPM2_HMAC_Start() 58 if(in->hashAlg != TPM_ALG_NULL && in->hashAlg != hashAlg) in TPM2_HMAC_Start() 59 hashAlg = TPM_ALG_NULL; in TPM2_HMAC_Start() 62 if(hashAlg == TPM_ALG_NULL) in TPM2_HMAC_Start() 69 return ObjectCreateHMACSequence(hashAlg, in TPM2_HMAC_Start()
|
D | HMAC.c | 27 TPMI_ALG_HASH hashAlg; in TPM2_HMAC() local 51 hashAlg = in->hashAlg; in TPM2_HMAC() 55 hashAlg in TPM2_HMAC() 56 = publicArea->parameters.keyedHashDetail.scheme.details.hmac.hashAlg; in TPM2_HMAC() 58 if(in->hashAlg != TPM_ALG_NULL && in->hashAlg != hashAlg) in TPM2_HMAC() 59 hashAlg = TPM_ALG_NULL; in TPM2_HMAC() 62 if(hashAlg == TPM_ALG_NULL) in TPM2_HMAC() 68 out->outHMAC.t.size = CryptStartHMAC2B(hashAlg, in TPM2_HMAC()
|
D | CpriHash.c | 34 TPM_ALG_ID hashAlg in GetHashServer() argument 37 switch (hashAlg) in GetHashServer() 133 TPM_ALG_ID hashAlg in GetHashInfoPointer() argument 141 if(g_hashData[i].alg == hashAlg) in GetHashInfoPointer() 210 TPM_ALG_ID hashAlg // IN: hash algorithm to look up in _cpri__GetHashBlockSize() argument 213 return GetHashInfoPointer(hashAlg)->blockSize; in _cpri__GetHashBlockSize() 223 TPM_ALG_ID hashAlg, // IN: the algorithm to look up in _cpri__GetHashDER() argument 228 q = GetHashInfoPointer(hashAlg); in _cpri__GetHashDER() 245 TPM_ALG_ID hashAlg // IN: hash algorithm to look up in _cpri__GetDigestSize() argument 248 return GetHashInfoPointer(hashAlg)->digestSize; in _cpri__GetDigestSize() [all …]
|
D | CpriHash_fp.h | 20 _cpri__HashBlock(TPM_ALG_ID hashAlg, // IN: The hash algorithm 28 _cpri__GetDigestSize(TPM_ALG_ID hashAlg // IN: hash algorithm to look up 31 _cpri__GetHashDER(TPM_ALG_ID hashAlg, // IN: the algorithm to look up 34 _cpri__KDFa(TPM_ALG_ID hashAlg, // IN: hash algorithm used in HMAC 48 _cpri__KDFe(TPM_ALG_ID hashAlg, // IN: hash algorithm used in HMAC 59 TPM_ALG_ID hashAlg, // IN: hash to use 64 _cpri__StartHMAC(TPM_ALG_ID hashAlg, // IN: the algorithm to use 72 _cpri__StartHash(TPM_ALG_ID hashAlg, // IN: hash algorithm 95 _cpri__GetHashBlockSize(TPM_ALG_ID hashAlg // IN: hash algorithm to look up
|
D | stubs_hash.c | 10 TPM_ALG_ID hashAlg, // IN: the algorithm to use in _cpri__StartHMAC() argument 19 UINT16 blockSize = _cpri__GetHashBlockSize(hashAlg); in _cpri__StartHMAC() 28 if((digestSize = _cpri__StartHash(hashAlg, FALSE, &localState)) == 0) in _cpri__StartHMAC() 51 if((digestSize = _cpri__StartHash(hashAlg, sequence, state)) > 0) in _cpri__StartHMAC() 71 UINT16 digestSize = _cpri__GetDigestSize(state->hashAlg); in _cpri__CompleteHMAC() 74 if(_cpri__StartHash(state->hashAlg, FALSE, &localState) != digestSize) in _cpri__CompleteHMAC() 82 TPM_ALG_ID hashAlg, // IN: hash algorithm used in HMAC in _cpri__KDFa() argument 118 if((hLen = (INT16) _cpri__GetDigestSize(hashAlg)) == 0) in _cpri__KDFa() 131 if(_cpri__StartHMAC(hashAlg, in _cpri__KDFa() 167 TPM_ALG_ID hashAlg, // IN: hash algorithm used in HMAC in _cpri__KDFe() argument [all …]
|
D | CryptUtil_fp.h | 117 CryptGetHashDigestSize(TPM_ALG_ID hashAlg // IN: hash algorithm 149 TPM_ALG_ID hashAlg, // IN: hash algorithm for the KDF 157 CryptGetHashDigestSize(TPM_ALG_ID hashAlg // IN: hash algorithm 185 #define CryptKDFa(hashAlg, key, label, contextU, contextV, sizeInBits, \ argument 187 TEST_HASH(hashAlg); \ 188 _cpri__KDFa(((TPM_ALG_ID)hashAlg), ((TPM2B *)key), ((const char *)label), \ 202 #define CryptKDFaOnce(hashAlg, key, label, contextU, contextV, sizeInBits, \ argument 204 TEST_HASH(hashAlg); \ 205 _cpri__KDFa(((TPM_ALG_ID)hashAlg), ((TPM2B *)key), ((const char *)label), \ 217 #define CryptKDFe(hashAlg, Z, label, partyUInfo, partyVInfo, sizeInBits, \ argument [all …]
|
D | EventSequenceComplete.c | 26 TPM_ALG_ID hashAlg; in TPM2_EventSequenceComplete() local 67 hashAlg = CryptGetHashAlgByIndex(i); in TPM2_EventSequenceComplete() 71 out->results.digests[out->results.count].hashAlg = hashAlg; in TPM2_EventSequenceComplete() 73 CryptGetHashDigestSize(hashAlg), in TPM2_EventSequenceComplete() 78 PCRExtend(in->pcrHandle, hashAlg, in TPM2_EventSequenceComplete() 79 CryptGetHashDigestSize(hashAlg), in TPM2_EventSequenceComplete()
|
D | CpriRSA.c | 340 TPM_ALG_ID hashAlg, // IN: algorithm to use for padding in OaepEncode() argument 354 INT32 hLen = _cpri__GetDigestSize(hashAlg); in OaepEncode() 376 retVal = _cpri__HashBlock(hashAlg, lSize, (BYTE *)label, hLen, pp); in OaepEncode() 394 if((retVal = _cpri__MGF1(dbSize, mask, hashAlg, hLen, seed)) < 0) in OaepEncode() 403 if((retVal = _cpri__MGF1(hLen, &padded[1], hashAlg, dbSize, pp)) < 0) in OaepEncode() 434 TPM_ALG_ID hashAlg, // IN: algorithm to use for padding in OaepDecode() argument 443 INT32 hLen = _cpri__GetDigestSize(hashAlg); in OaepDecode() 464 if((retVal = _cpri__MGF1(hLen, seedMask, hashAlg, in OaepDecode() 473 if((retVal = _cpri__MGF1(paddedSize-hLen-1, mask, hashAlg, in OaepDecode() 483 if((retVal=_cpri__HashBlock(hashAlg, lSize,(BYTE *)label, hLen, seedMask)) < 0) in OaepDecode() [all …]
|
D | CryptUtil.c | 154 TPMI_ALG_HASH hashAlg, // IN: hash algorithm in CryptStartHash() argument 161 TEST_HASH(hashAlg); in CryptStartHash() 164 if((retVal = _cpri__StartHash(hashAlg, FALSE, &hashState->state)) > 0) in CryptStartHash() 183 TPMI_ALG_HASH hashAlg, // IN: hash algorithm in CryptStartHashSequence() argument 190 TEST_HASH(hashAlg); in CryptStartHashSequence() 193 if((retVal = _cpri__StartHash(hashAlg, TRUE, &hashState->state)) > 0) in CryptStartHashSequence() 212 TPMI_ALG_HASH hashAlg, // IN: hash algorithm in CryptStartHMAC() argument 225 TEST_HASH(hashAlg); in CryptStartHMAC() 228 if((retVal = _cpri__StartHMAC(hashAlg, FALSE, &hashState->state, keySize, key, in CryptStartHMAC() 249 TPMI_ALG_HASH hashAlg, // IN: hash algorithm in CryptStartHMACSequence() argument [all …]
|
D | Attest_spt.c | 72 TPMI_ALG_HASH hashAlg; in FillInAttestInfo() local 76 hashAlg = CONTEXT_INTEGRITY_HASH_ALG; in FillInAttestInfo() 82 hashAlg = signObject->publicArea.nameAlg; in FillInAttestInfo() 84 KDFa(hashAlg, &gp.shProof.b, "OBFUSCATE", in FillInAttestInfo() 132 TPMI_ALG_HASH hashAlg; in SignAttestInfo() local 160 hashAlg = scheme->details.any.hashAlg; in SignAttestInfo() 161 digest.t.size = CryptStartHash(hashAlg, &hashState); in SignAttestInfo() 168 CryptStartHash(hashAlg, &hashState); in SignAttestInfo()
|
D | Object_spt.c | 104 TPM_ALG_ID hashAlg, // IN: hash algorithm for KDFa in ComputeProtectionKeyParms() argument 137 KDFa(hashAlg, (TPM2B *)seed, "STORAGE", (TPM2B *)name, NULL, in ComputeProtectionKeyParms() 158 TPMI_ALG_HASH hashAlg, // IN: algorithm to use for integrity in ComputeOuterIntegrity() argument 173 hmacKey.t.size = CryptGetHashDigestSize(hashAlg); in ComputeOuterIntegrity() 175 KDFa(hashAlg, (TPM2B *)seed, "INTEGRITY", NULL, NULL, in ComputeOuterIntegrity() 178 integrity->t.size = CryptStartHMAC2B(hashAlg, &hmacKey.b, &hmacState); in ComputeOuterIntegrity() 195 TPM_ALG_ID hashAlg, // IN: hash algorithm for inner wrap in ComputeInnerIntegrity() argument 204 integrity->t.size = CryptStartHash(hashAlg, &hashState); in ComputeInnerIntegrity() 225 TPM_ALG_ID hashAlg, // IN: hash algorithm for inner wrap in ProduceInnerIntegrity() argument 239 integritySize = sizeof(UINT16) + CryptGetHashDigestSize(hashAlg); in ProduceInnerIntegrity() [all …]
|
D | Quote.c | 27 TPMI_ALG_HASH hashAlg; in TPM2_Quote() local 54 hashAlg = in->inScheme.details.any.hashAlg; in TPM2_Quote() 56 if(hashAlg == TPM_ALG_NULL) in TPM2_Quote() 60 PCRComputeCurrentDigest(hashAlg, in TPM2_Quote()
|
D | Entity.c | 252 TPMI_ALG_HASH hashAlg = TPM_ALG_NULL; in EntityGetAuthPolicy() local 262 hashAlg = gp.ownerAlg; in EntityGetAuthPolicy() 267 hashAlg = gp.endorsementAlg; in EntityGetAuthPolicy() 272 hashAlg = gc.platformAlg; in EntityGetAuthPolicy() 277 hashAlg = gp.lockoutAlg; in EntityGetAuthPolicy() 291 hashAlg = object->publicArea.nameAlg; in EntityGetAuthPolicy() 300 hashAlg = nvIndex.publicArea.nameAlg; in EntityGetAuthPolicy() 305 hashAlg = PCRGetAuthPolicy(handle, authPolicy); in EntityGetAuthPolicy() 312 return hashAlg; in EntityGetAuthPolicy()
|
D | SetPrimaryPolicy.c | 27 if(in->authPolicy.t.size != CryptGetHashDigestSize(in->hashAlg)) in TPM2_SetPrimaryPolicy() 44 gp.ownerAlg = in->hashAlg; in TPM2_SetPrimaryPolicy() 50 gp.endorsementAlg = in->hashAlg; in TPM2_SetPrimaryPolicy() 56 gc.platformAlg = in->hashAlg; in TPM2_SetPrimaryPolicy() 62 gp.lockoutAlg = in->hashAlg; in TPM2_SetPrimaryPolicy()
|
D | CpriRSA_fp.h | 18 TPM_ALG_ID hashAlg, // IN: in case this is needed for the scheme 28 TPM_ALG_ID hashAlg, // IN: in case this is needed 37 hashAlg, // IN: hash algorithm to use in the key generation proce 49 TPM_ALG_ID hashAlg, // IN: hash algorithm for PKSC1v1_5 64 TPM_ALG_ID hashAlg, // IN: hash algorithm
|
D | PolicyAuthorize.c | 29 TPM_ALG_ID hashAlg; in TPM2_PolicyAuthorize() local 38 hashAlg = BYTE_ARRAY_TO_UINT16(in->keySign.t.name); in TPM2_PolicyAuthorize() 42 digestSize = CryptGetHashDigestSize(hashAlg); in TPM2_PolicyAuthorize() 62 authHash.t.size = CryptStartHash(hashAlg, &hashState); in TPM2_PolicyAuthorize()
|
D | PCR_SetAuthPolicy.c | 35 if(in->authPolicy.t.size != CryptGetHashDigestSize(in->hashAlg)) in TPM2_PCR_SetAuthPolicy() 45 gp.pcrPolicies.hashAlg[groupIndex] = in->hashAlg; in TPM2_PCR_SetAuthPolicy()
|
D | Sign.c | 54 in->inScheme.details.any.hashAlg, in TPM2_Sign() 68 in->inScheme.details.any.hashAlg != TPM_ALG_NULL && in TPM2_Sign() 71 != CryptGetHashDigestSize(in->inScheme.details.any.hashAlg)) in TPM2_Sign()
|
D | SequenceComplete.c | 44 TPM_ALG_ID hashAlg = hashObject->state.hashState[0].state.hashAlg; in TPM2_SequenceComplete() local 82 TicketComputeHashCheck(out->validation.hierarchy, hashAlg, in TPM2_SequenceComplete()
|
D | CpriECC_fp.h | 61 hashAlg, // IN: hash algorithm to use in the key generation process 78 TPM_ALG_ID hashAlg, // IN: the hash algorithm if need 90 hashAlg, // IN: the hash algorithm used (not used in all schemes)
|
D | HashSequenceStart.c | 24 if(in->hashAlg == TPM_ALG_NULL) in TPM2_HashSequenceStart() 31 return ObjectCreateHashSequence(in->hashAlg, &in->auth, &out->sequenceHandle); in TPM2_HashSequenceStart()
|
D | PCR_Extend.c | 57 PCRExtend(in->pcrHandle, in->digests.digests[i].hashAlg, in TPM2_PCR_Extend() 58 CryptGetHashDigestSize(in->digests.digests[i].hashAlg), in TPM2_PCR_Extend()
|
D | RSAKeySieve.c | 159 UINT16 digestSize = _cpri__GetDigestSize(ktx->hashAlg); in RandomForRsa() 720 TPM_ALG_ID hashAlg, // IN: the hash algorithm in KDFaContextStart() argument 726 UINT16 digestSize = _cpri__GetDigestSize(hashAlg); in KDFaContextStart() 732 _cpri__StartHMAC(hashAlg, FALSE, &(ktx->iPadCtx), seed->size, seed->buffer, in KDFaContextStart() 734 _cpri__StartHash(hashAlg, FALSE, &(ktx->oPadCtx)); in KDFaContextStart() 737 ktx->hashAlg = hashAlg; in KDFaContextStart() 781 TPM_ALG_ID hashAlg, // IN: hash algorithm to use in the key in _cpri__GenerateKeyRSA() argument 811 ktxPtr = KDFaContextStart(&ktx, seed, hashAlg, extra, pCtr, keySizeInBits); in _cpri__GenerateKeyRSA()
|
D | Ticket.c | 129 TPM_ALG_ID hashAlg, // IN: the hash algorithm used to create in TicketComputeHashCheck() argument 148 CryptUpdateDigestInt(&hmacState, sizeof(hashAlg), &hashAlg); in TicketComputeHashCheck()
|
/external/libchrome/crypto/third_party/nss/ |
D | rsawrapr.c | 20 MGF1(HASH_HashType hashAlg, unsigned char *mask, unsigned int maskLen, in MGF1() argument 30 hash = HASH_GetHashObject(hashAlg); in MGF1() 75 HASH_HashType hashAlg, HASH_HashType maskHashAlg, in emsa_pss_verify() argument 85 hash = HASH_GetHashObject(hashAlg); in emsa_pss_verify()
|