/base/security/device_auth/services/protocol/src/iso_protocol/ |
D | iso_protocol_common.c | 31 params->randSelf.length = RAND_BYTE_LEN; in InitIsoBaseParams() 32 params->randSelf.val = (uint8_t *)HcMalloc(params->randSelf.length, 0); in InitIsoBaseParams() 38 params->randPeer.length = RAND_BYTE_LEN; in InitIsoBaseParams() 39 params->randPeer.val = (uint8_t *)HcMalloc(params->randPeer.length, 0); in InitIsoBaseParams() 46 params->sessionKey.length = ISO_SESSION_KEY_LEN; in InitIsoBaseParams() 47 params->sessionKey.val = (uint8_t *)HcMalloc(params->sessionKey.length, 0); in InitIsoBaseParams() 91 int length = params->randSelf.length + params->randPeer.length + params->authIdSelf.length + in IsoCalSelfToken() local 92 params->authIdPeer.length; in IsoCalSelfToken() 93 uint8_t *messagePeer = (uint8_t *)HcMalloc(length, 0); in IsoCalSelfToken() 99 if (memcpy_s(messagePeer, length, params->randPeer.val, params->randPeer.length) != EOK) { in IsoCalSelfToken() [all …]
|
/base/security/device_auth/frameworks/deviceauth_lite/source/base/ |
D | base.h | 113 uint32_t length; member 118 uint32_t length; member 123 uint32_t length; member 128 uint32_t length; member 134 uint32_t length; member 140 uint32_t length; member 157 uint32_t length; member 162 uint32_t length; member 167 uint32_t length; member 172 uint32_t length; member [all …]
|
/base/security/device_auth/services/protocol/src/pake_protocol/pake_v2_protocol/ |
D | pake_v2_protocol_common.c | 74 params->salt.length = PAKE_SALT_LEN; in AllocDefaultParams() 75 params->salt.val = (uint8_t *)HcMalloc(params->salt.length, 0); in AllocDefaultParams() 81 params->sharedSecret.length = SHA256_LEN; in AllocDefaultParams() 82 params->sharedSecret.val = (uint8_t *)HcMalloc(params->sharedSecret.length, 0); in AllocDefaultParams() 88 params->sessionKey.length = PAKE_SESSION_KEY_LEN; in AllocDefaultParams() 89 params->sessionKey.val = (uint8_t *)HcMalloc(params->sessionKey.length, 0); in AllocDefaultParams() 95 params->kcfData.length = HMAC_LEN; in AllocDefaultParams() 96 params->kcfData.val = (uint8_t *)HcMalloc(params->kcfData.length, 0); in AllocDefaultParams() 102 params->kcfDataPeer.length = HMAC_LEN; in AllocDefaultParams() 103 params->kcfDataPeer.val = (uint8_t *)HcMalloc(params->kcfDataPeer.length, 0); in AllocDefaultParams() [all …]
|
/base/security/device_auth/services/protocol/src/pake_protocol/pake_v1_protocol/ |
D | pake_v1_protocol_common.c | 70 params->salt.length = PAKE_SALT_LEN; in AllocDefaultParams() 71 params->salt.val = (uint8_t *)HcMalloc(params->salt.length, 0); in AllocDefaultParams() 77 params->challengeSelf.length = PAKE_CHALLENGE_LEN; in AllocDefaultParams() 78 params->challengeSelf.val = (uint8_t *)HcMalloc(params->challengeSelf.length, 0); in AllocDefaultParams() 84 params->challengePeer.length = PAKE_CHALLENGE_LEN; in AllocDefaultParams() 85 params->challengePeer.val = (uint8_t *)HcMalloc(params->challengePeer.length, 0); in AllocDefaultParams() 91 params->sessionKey.length = PAKE_SESSION_KEY_LEN; in AllocDefaultParams() 92 params->sessionKey.val = (uint8_t *)HcMalloc(params->sessionKey.length, 0); in AllocDefaultParams() 98 params->hmacKey.length = PAKE_HMAC_KEY_LEN; in AllocDefaultParams() 99 params->hmacKey.val = (uint8_t *)HcMalloc(params->hmacKey.length, 0); in AllocDefaultParams() [all …]
|
/base/usb/usb_manager/test/native/js_unittest/ |
D | UsbDevicePipeJsunitEx.test.js | 33 if (usbPortList.length > 0) { 64 for (var k = 0; k < testParam.config.interfaces[j].endpoints.length; k++) { 92 if (testParam.config.interfaces[j].endpoints.length == 0) { 100 for (var j = 0; j < testParam.config.interfaces.length; j++) { 125 console.info('usb case gDeviceList.length: ' + gDeviceList.length); 126 for (var i = 0; i < gDeviceList.length; i++) { 235 if (gDeviceList.length == 0) { 241 if (gDeviceList[0].configs.length == 0) { 247 for (var j = 0; j < gDeviceList[0].configs.length; j++) { 248 if (gDeviceList[0].configs[j].interfaces.length == 0) { [all …]
|
/base/security/device_auth/services/authenticators/src/account_unrelated/ |
D | das_task_common.c | 173 serviceIdPlain.length = pkgName->length + serviceType->length; in CombineServiceId() 174 serviceIdPlain.val = (uint8_t *)HcMalloc(serviceIdPlain.length, 0); in CombineServiceId() 181 if (memcpy_s(serviceIdPlain.val, serviceIdPlain.length, pkgName->val, pkgName->length) != EOK) { in CombineServiceId() 186 if (memcpy_s(serviceIdPlain.val + pkgName->length, serviceIdPlain.length - pkgName->length, in CombineServiceId() 187 serviceType->val, serviceType->length) != EOK) { in CombineServiceId() 208 keyAliasBuff.length = serviceId->length + authId->length + keyType->length; in CombineKeyAlias() 209 keyAliasBuff.val = (uint8_t *)HcMalloc(keyAliasBuff.length, 0); in CombineKeyAlias() 215 uint32_t totalLen = keyAliasBuff.length; in CombineKeyAlias() 217 if (memcpy_s(keyAliasBuff.val, totalLen, serviceId->val, serviceId->length) != EOK) { in CombineKeyAlias() 222 usedLen = usedLen + serviceId->length; in CombineKeyAlias() [all …]
|
/base/security/device_auth/frameworks/deviceauth_lite/source/key_agreement/ |
D | sts_client.c | 87 random_value.random_value, random_value.length) != EOK) { in build_start_request_data() 90 sts_client->my_challenge.length = random_value.length; in build_start_request_data() 149 int len = sts_client->peer_public_key.length + sts_client->peer_id.length + in generate_sign_message() 150 sts_client->self_public_key.length + sts_client->self_id.length; in generate_sign_message() 158 …cpy_s(info + pos, len - pos, sts_client->peer_public_key.stpk, sts_client->peer_public_key.length); in generate_sign_message() 159 pos += sts_client->peer_public_key.length; in generate_sign_message() 160 (void)memcpy_s(info + pos, len - pos, sts_client->peer_id.auth_id, sts_client->peer_id.length); in generate_sign_message() 161 pos += sts_client->peer_id.length; in generate_sign_message() 162 …cpy_s(info + pos, len - pos, sts_client->self_public_key.stpk, sts_client->self_public_key.length); in generate_sign_message() 163 pos += sts_client->self_public_key.length; in generate_sign_message() [all …]
|
D | sts_server.c | 190 if (salt.length == 0) { in parse_start_request_data() 194 …y_s(sts_server->salt.salt, sizeof(sts_server->salt.salt), salt.random_value, salt.length) != EOK) { in parse_start_request_data() 197 sts_server->salt.length = salt.length; in parse_start_request_data() 223 int32_t len = sts_server->self_public_key.length + sts_server->self_id.length + in generate_sts_response_sign() 224 sts_server->peer_public_key.length + sts_server->peer_id.length; in generate_sts_response_sign() 232 …py_s(info2 + pos, len - pos, sts_server->self_public_key.stpk, sts_server->self_public_key.length); in generate_sts_response_sign() 233 pos += sts_server->self_public_key.length; in generate_sts_response_sign() 234 (void)memcpy_s(info2 + pos, len - pos, sts_server->self_id.auth_id, sts_server->self_id.length); in generate_sts_response_sign() 235 pos += sts_server->self_id.length; in generate_sts_response_sign() 236 …py_s(info2 + pos, len - pos, sts_server->peer_public_key.stpk, sts_server->peer_public_key.length); in generate_sts_response_sign() [all …]
|
/base/usb/usb_manager/services/native/src/ |
D | usb_descriptor_parser.cpp | 39 int32_t UsbDescriptorParser::ParseDeviceDescriptor(const uint8_t *buffer, uint32_t length, UsbDevic… in ParseDeviceDescriptor() argument 41 if (buffer == nullptr || length == 0) { in ParseDeviceDescriptor() 46 USB_HILOGI(MODULE_USB_SERVICE, "parse begin length=%{public}u", length); in ParseDeviceDescriptor() 48 if (length < deviceDescriptorSize) { in ParseDeviceDescriptor() 75 const uint8_t *buffer, uint32_t length, uint32_t &cursor, USBConfig &config) in ParseConfigDescriptor() argument 77 if (buffer == nullptr || length == 0) { in ParseConfigDescriptor() 81 …USB_HILOGI(MODULE_USB_SERVICE, "parse begin length=%{public}u, cursor=%{public}u", length, cursor); in ParseConfigDescriptor() 83 if (length < configDescriptorSize) { in ParseConfigDescriptor() 101 for (int32_t i = 0; (i < configDescriptor.bNumInterfaces) && (cursor < length); ++i) { in ParseConfigDescriptor() 105 … buffer + cursor + interfaceCursor, length - cursor - interfaceCursor, interfaceCursor, interface); in ParseConfigDescriptor() [all …]
|
/base/telephony/sms_mms/services/gsm/ |
D | gsm_sms_tpdu_codec.cpp | 94 int length = 0; in EncodeSubmit() local 109 length = GsmSmsParamCodec::EncodeAddress(&pSubmit->destAddress, &address); in EncodeSubmit() 110 ret = memcpy_s(&(pTpdu[offset]), length, address, length); in EncodeSubmit() 114 offset += length; in EncodeSubmit() 115 TELEPHONY_LOGI("TP-DA len: =%{public}d,TP-MR msgRef:=%{public}d", length, pSubmit->msgRef); in EncodeSubmit() 120 length = GsmSmsParamCodec::EncodeDCS(&pSubmit->dcs, &dcs); in EncodeSubmit() 121 ret = memcpy_s(&(pTpdu[offset]), length, dcs, length); in EncodeSubmit() 125 offset += length; in EncodeSubmit() 126 TELEPHONY_LOGI("TP-DCS length : =%{public}d", length); in EncodeSubmit() 129 length = GsmSmsParamCodec::EncodeTime(&pSubmit->validityPeriod, &vpTime); in EncodeSubmit() [all …]
|
/base/security/device_auth/services/protocol/src/ |
D | protocol_common.c | 27 (void)memset_s(key->val, key->length, 0, key->length); in FreeAndCleanKey() 30 key->length = 0; in FreeAndCleanKey() 40 (void)memset_s(param->val, param->length, 0, param->length); in InitSingleParam() 43 param->length = len; in InitSingleParam() 44 param->val = (uint8_t *)HcMalloc(param->length, 0); in InitSingleParam()
|
/base/security/device_auth/deps_adapter/key_management_adapter/impl/src/small/ |
D | huks_adapter.c | 35 CHECK_LEN_ZERO_RETURN_ERROR_CODE(inParams[i]->length, paramTags[i]); in BaseCheckParams() 77 CHECK_LEN_ZERO_RETURN_ERROR_CODE(message->length, "message->length"); in Sha256() 81 CHECK_LEN_EQUAL_RETURN(hash->length, SHA256_LEN, "hash->length"); in Sha256() 83 struct HksBlob srcBlob = { message->length, message->val }; in Sha256() 84 struct HksBlob hashBlob = { hash->length, hash->val }; in Sha256() 112 CHECK_LEN_ZERO_RETURN_ERROR_CODE(rand->length, "rand->length"); in GenerateRandom() 114 struct HksBlob randBlob = { rand->length, rand->val }; in GenerateRandom() 128 CHECK_LEN_ZERO_RETURN_ERROR_CODE(keyAlias->length, "keyAlias->length"); in CheckKeyExist() 130 struct HksBlob keyAliasBlob = { keyAlias->length, keyAlias->val }; in CheckKeyExist() 144 CHECK_LEN_ZERO_RETURN_ERROR_CODE(keyAlias->length, "keyAlias->length"); in DeleteKey() [all …]
|
/base/security/device_security_level/services/common/ |
D | dslm_crypto.c | 23 void GenerateRandom(RandomValue *rand, uint32_t length) in GenerateRandom() argument 28 rand->length = (length > RANDOM_MAX_LEN) ? RANDOM_MAX_LEN : length; in GenerateRandom() 30 RAND_bytes(&rand->value[0], rand->length); in GenerateRandom()
|
/base/security/device_auth/services/authenticators/src/account_unrelated/pake_task/standard_exchange_task/ |
D | standard_exchange_message_util.c | 28 uint32_t exAuthInfoLen = nonce->length + cipher->length; in PackageNonceAndCipherToJson() 35 if (memcpy_s(exAuthInfoVal, exAuthInfoLen, nonce->val, nonce->length) != EOK) { in PackageNonceAndCipherToJson() 40 if (memcpy_s(exAuthInfoVal + nonce->length, exAuthInfoLen - nonce->length, in PackageNonceAndCipherToJson() 41 cipher->val, cipher->length) != EOK) { in PackageNonceAndCipherToJson() 74 if (memcpy_s(nonce->val, nonce->length, exAuthInfoVal, nonce->length) != EOK) { in ParseNonceAndCipherFromJson() 80 res = InitSingleParam(cipher, exAuthInfoLen - nonce->length); in ParseNonceAndCipherFromJson() 85 if (memcpy_s(cipher->val, cipher->length, exAuthInfoVal + nonce->length, in ParseNonceAndCipherFromJson() 86 exAuthInfoLen - nonce->length) != EOK) { in ParseNonceAndCipherFromJson() 119 params->baseParams.challengePeer.val, params->baseParams.challengePeer.length); in GetPeerChallenge()
|
D | common_standard_bind_exchange.c | 32 params->pubKeyPeer.length = PAKE_ED25519_KEY_PAIR_LEN; in InitStandardBindExchangeParams() 33 params->pubKeyPeer.val = (uint8_t *)HcMalloc(params->pubKeyPeer.length, 0); in InitStandardBindExchangeParams() 39 params->pubKeySelf.length = PAKE_ED25519_KEY_PAIR_LEN; in InitStandardBindExchangeParams() 40 params->pubKeySelf.val = (uint8_t *)HcMalloc(params->pubKeySelf.length, 0); in InitStandardBindExchangeParams() 46 params->nonce.length = STANDARD_BIND_EXCHANGE_NONCE_LEN; in InitStandardBindExchangeParams() 47 params->nonce.val = (uint8_t *)HcMalloc(params->nonce.length, 0); in InitStandardBindExchangeParams() 53 params->authInfo.length = 0; in InitStandardBindExchangeParams() 55 params->exInfoCipher.length = 0; in InitStandardBindExchangeParams() 117 pakeParams->baseParams.idSelf.length), res); in PackageAuthInfo() 119 exchangeParams->pubKeySelf.length), res); in PackageAuthInfo() [all …]
|
/base/security/device_security_level/test/dslm_unit_test/ |
D | dslm_oem_property_test.cpp | 684 uint32_t length = strlen(data) + 1; variable 685 const DataBuffer srcData = {.length = length, .data = (uint8_t *)data}; 686 const DataBuffer sigData = {.length = length, .data = (uint8_t *)data}; 697 uint32_t length = strlen(data) + 1; variable 702 const DataBuffer srcData = {.length = length, .data = nullptr}; 703 const DataBuffer sigData = {.length = length, .data = (uint8_t *)data}; 704 const DataBuffer pbkData = {.length = length, .data = (uint8_t *)data}; 711 const DataBuffer srcData = {.length = length, .data = (uint8_t *)data}; 713 const DataBuffer sigData = {.length = length, .data = nullptr}; 714 const DataBuffer pbkData = {.length = length, .data = (uint8_t *)data}; [all …]
|
/base/security/device_auth/services/key_agree_sdk/src/ |
D | key_agree_sdk.c | 36 …if ((sharedSecret->length < MIN_SHARED_SECRET_LENGTH) || (sharedSecret->length > MAX_SHARED_SECRET… in CheckKeyAgreeStartSessionParams() 40 …if (strnlen((const char *)(sharedSecret->data), sharedSecret->length) > sharedSecret->length + 1) { in CheckKeyAgreeStartSessionParams() 44 if ((deviceId->length < MIN_DEVICE_ID_LENGTH) || (deviceId->length > MAX_DEVICE_ID_LENGTH)) { in CheckKeyAgreeStartSessionParams() 48 if (strnlen((const char *)(deviceId->data), deviceId->length) > deviceId->length + 1) { in CheckKeyAgreeStartSessionParams() 79 if (memcpy_s(out->data, out->length, returnStr, returnStrLen + 1) != EOK) { in BuildErrorMessage() 82 out->length = returnStrLen + 1; in BuildErrorMessage() 112 if (InitSingleParam(&(spekeSession->sharedSecret), sharedSecret->length) != HC_SUCCESS) { in InitKeyAgreeStartSessionParams() 117 if (memcpy_s(spekeSession->sharedSecret.val, spekeSession->sharedSecret.length, in InitKeyAgreeStartSessionParams() 118 sharedSecret->data, sharedSecret->length) != HC_SUCCESS) { in InitKeyAgreeStartSessionParams() 123 if (InitSingleParam(&(spekeSession->deviceId), deviceId->length) != HC_SUCCESS) { in InitKeyAgreeStartSessionParams() [all …]
|
/base/security/device_auth/frameworks/deviceauth_lite/source/auth_info/ |
D | exchange_auth_info.c | 148 plain.size = auth_info.length + sign_result.length; in build_exchange_response_data() 156 (void)memcpy_s(plain.val, plain.size, auth_info.val, auth_info.length); in build_exchange_response_data() 157 plain.length = auth_info.length; in build_exchange_response_data() 159 …(void)memcpy_s(plain.val + plain.length, plain.size - plain.length, sign_result.signature, sign_re… in build_exchange_response_data() 160 plain.length += sign_result.length; in build_exchange_response_data() 182 if (service_id.length == 0) { in get_self_key_id() 191 if (alias.length == 0) { in get_self_key_id() 216 if (payload->length <= HC_SIGNATURE_LEN) { in get_field_from_request_payload() 217 LOGE("Peer public key signature info length is %d", payload->length); in get_field_from_request_payload() 222 auth_info->length -= HC_SIGNATURE_LEN; in get_field_from_request_payload() [all …]
|
D | exchange_auth_info_client.c | 95 if (key->length < PAKE_SESSION_KEY_LENGTH) { in parse_exchange_response_data() 152 plain.size = auth_info.length + sign_result.length; in build_exchange_request() 159 if (memcpy_s(plain.val, plain.size, auth_info.val, auth_info.length) != EOK) { in build_exchange_request() 164 plain.length = auth_info.length; in build_exchange_request() 166 …if (memcpy_s(plain.val + plain.length, plain.size - plain.length, sign_result.signature, sign_resu… in build_exchange_request() 171 plain.length += sign_result.length; in build_exchange_request() 187 if (service_id.length == 0) { in get_self_key_id() 196 if (alias.length == 0) { in get_self_key_id() 222 if (payload->length <= HC_SIGNATURE_LEN) { in get_field_from_request_payload() 223 LOGE("Peer public key signature info length is %d", payload->length); in get_field_from_request_payload() [all …]
|
/base/security/device_auth/services/authenticators/src/account_related/auth/pake_v2_auth_task/ |
D | pake_v2_auth_task_common.c | 65 .length = SHA256_LEN in VerifyPkSignPeer() 77 .length = params->pkInfoPeer.length in VerifyPkSignPeer() 81 .length = params->pkInfoSignPeer.length in VerifyPkSignPeer() 101 .length = SHA256_LEN in GenerateEcdhSharedKey() 111 .keyLen = aliasBuff.length, in GenerateEcdhSharedKey() 126 params->pakeParams.psk.length = sharedKeyAliasLen; in GenerateEcdhSharedKey() 143 param->length = len; in InitCharStringBuff() 155 params->devIdPeer.length + deviceIdPeerLen) != HC_SUCCESS) { in ExtractPakePeerId() 159 …(void)memcpy_s(params->pakeParams.idPeer.val, params->pakeParams.idPeer.length, params->devIdPeer.… in ExtractPakePeerId() 160 params->devIdPeer.length); in ExtractPakePeerId() [all …]
|
/base/security/access_token/frameworks/common/src/ |
D | data_validator.cpp | 24 return !bundleName.empty() && (bundleName.length() <= MAX_LENGTH); in IsBundleNameValid() 29 return label.length() <= MAX_LENGTH; in IsLabelValid() 34 return desc.length() <= MAX_LENGTH; in IsDescValid() 39 return !permissionName.empty() && (permissionName.length() <= MAX_LENGTH); in IsPermissionNameValid() 49 return !appIDDesc.empty() && (appIDDesc.length() <= MAX_APPIDDESC_LENGTH); in IsAppIDDescValid() 54 return !domain.empty() && (domain.length() <= MAX_LENGTH); in IsDomainValid() 64 return !processName.empty() && (processName.length() <= MAX_LENGTH); in IsProcessNameValid() 69 return !deviceId.empty() && (deviceId.length() <= MAX_LENGTH); in IsDeviceIdValid() 74 return !dcap.empty() && (dcap.length() <= MAX_DCAP_LENGTH); in IsDcapValid()
|
/base/security/device_auth/deps_adapter/key_management_adapter/impl/src/standard/ |
D | huks_adapter.c | 47 CHECK_LEN_ZERO_RETURN_ERROR_CODE(inParams[i]->length, paramTags[i]); in BaseCheckParams() 89 CHECK_LEN_ZERO_RETURN_ERROR_CODE(message->length, "message->length"); in Sha256() 93 CHECK_LEN_EQUAL_RETURN(hash->length, SHA256_LEN, "hash->length"); in Sha256() 95 struct HksBlob srcBlob = { message->length, message->val }; in Sha256() 96 struct HksBlob hashBlob = { hash->length, hash->val }; in Sha256() 124 CHECK_LEN_ZERO_RETURN_ERROR_CODE(rand->length, "rand->length"); in GenerateRandom() 126 struct HksBlob randBlob = { rand->length, rand->val }; in GenerateRandom() 140 CHECK_LEN_ZERO_RETURN_ERROR_CODE(keyAlias->length, "keyAlias->length"); in CheckKeyExist() 142 struct HksBlob keyAliasBlob = { keyAlias->length, keyAlias->val }; in CheckKeyExist() 156 CHECK_LEN_ZERO_RETURN_ERROR_CODE(keyAlias->length, "keyAlias->length"); in DeleteKey() [all …]
|
/base/update/ota_lite/frameworks/source/verify/ |
D | hota_verify.c | 39 void HotaHashCalc(const uint8 *buffer, uint32 length) in HotaHashCalc() argument 46 AppSha256Update(&g_sha256, buffer, length); in HotaHashCalc() 50 int32 HotaGetHash(uint8 *buffer, uint32 length) in HotaGetHash() argument 57 if (memset_s(buffer, length, 0, length) != EOK) { in HotaGetHash() 61 if (length >= HASH_LENGTH) { in HotaGetHash() 106 uint32 length = 0; in HotaSignVerifyByHash() local 112 uint8 *keyBuf = HotaGetPubKey(&length); in HotaSignVerifyByHash() 117 int ret = AppRsaDecodePublicKey(&rsa, keyBuf, length); in HotaSignVerifyByHash() 155 uint8 *HotaGetPubKey(uint32 *length) in HotaGetPubKey() argument 157 return HotaHalGetPubKey(length); in HotaGetPubKey()
|
/base/hiviewdfx/hisysevent/frameworks/native/util/ |
D | string_util.cpp | 24 if (src.length() > len) { in CopyCString() 27 return strcpy_s(dst, src.length() + 1, src.c_str()); in CopyCString() 32 if (src.length() > len) { in CreateCString() 35 char* data = new(std::nothrow) char[src.length() + 1]{0}; in CreateCString() 36 if (auto res = strcpy_s(data, src.length() + 1, src.c_str()); res != 0) { in CreateCString() 46 if (str.length() > len) { in ConvertCString() 49 char* data = new(std::nothrow) char[str.length() + 1]{0}; in ConvertCString() 50 if (auto res = strcpy_s(data, str.length() + 1, str.c_str()); res != 0) { in ConvertCString()
|
/base/security/device_auth/deps_adapter/key_management_adapter/impl/src/mini/ |
D | huks_adapter.c | 40 CHECK_LEN_ZERO_RETURN_ERROR_CODE(inParams[i]->length, paramTags[i]); in BaseCheckParams() 108 CHECK_LEN_ZERO_RETURN_ERROR_CODE(message->length, "message->length"); in Sha256() 112 CHECK_LEN_EQUAL_RETURN(hash->length, SHA256_LEN, "hash->length"); in Sha256() 114 struct HksBlob srcBlob = { message->length, message->val }; in Sha256() 115 struct HksBlob hashBlob = { hash->length, hash->val }; in Sha256() 143 CHECK_LEN_ZERO_RETURN_ERROR_CODE(rand->length, "rand->length"); in GenerateRandom() 145 struct HksBlob randBlob = { rand->length, rand->val }; in GenerateRandom() 159 CHECK_LEN_ZERO_RETURN_ERROR_CODE(keyAlias->length, "keyAlias->length"); in CheckKeyExist() 161 struct HksBlob keyAliasBlob = { keyAlias->length, keyAlias->val }; in CheckKeyExist() 175 CHECK_LEN_ZERO_RETURN_ERROR_CODE(keyAlias->length, "keyAlias->length"); in DeleteKey() [all …]
|