Home
last modified time | relevance | path

Searched refs:HASH_LENGTH (Results 1 – 8 of 8) sorted by relevance

/base/update/sys_installer_lite/frameworks/source/verify/
Dhota_verify.c24 static uint8 g_hash[HASH_LENGTH] = {0};
32 if (memset_s(g_hash, HASH_LENGTH, 0, HASH_LENGTH) != EOK) { in HotaHashInit()
61 if (length >= HASH_LENGTH) { in HotaGetHash()
64 if (memcpy_s(buffer, HASH_LENGTH, g_hash, HASH_LENGTH) != EOK) { in HotaGetHash()
79 if ((dataAddr == NULL) || (hash == NULL) || (dataLen == 0) || (hashLen < HASH_LENGTH)) { in HotaCalcImageHash()
139 uint8 imageHashLocal[HASH_LENGTH] = {0}; in HotaSignVerify()
140 if (HotaCalcImageHash(image, imgLen, imageHashLocal, HASH_LENGTH) != OHOS_SUCCESS) { in HotaSignVerify()
146 int ret = HotaSignVerifyByHash(imageHashLocal, HASH_LENGTH, imageSign, signLen); in HotaSignVerify()
Dhota_verify.h28 #define HASH_LENGTH 32 macro
/base/update/sys_installer_lite/frameworks/test/unittest/common/src/
Dota_test.cpp307 if ((dataAddr == nullptr) || (hash == nullptr) || (dataLen == 0) || (hashLen < HASH_LENGTH)) { in HotaCalcImageHash()
399 unsigned char hashOut[HASH_LENGTH] = {0};
400 EXPECT_EQ(0, HotaGetHash(hashOut, HASH_LENGTH));
442 uint8 imageHashLocal[HASH_LENGTH] = {0};
443 …alcImageHash(reinterpret_cast<uint8 *>(g_otaPkg), INFO_COMP_DATA_LEN, imageHashLocal, HASH_LENGTH);
446 ret = AppVerifyData(&rsa, imageHashLocal, HASH_LENGTH,
/base/startup/init/services/modules/udid/
Dudid_adp.c35 unsigned char hash[HASH_LENGTH] = { 0 }; in GetSha256Value()
43 for (size_t i = 0; i < HASH_LENGTH; i++) { in GetSha256Value()
/base/startup/init/interfaces/innerkits/syspara/
Dparam_comm.h29 #define HASH_LENGTH 32 macro
/base/update/sys_installer_lite/frameworks/source/updater/
Dhota_updater.c27 #define HASH_LENGTH 32 macro
77 unsigned char shaData[HASH_LENGTH];
312 unsigned char hashOut[HASH_LENGTH] = {0}; in ParseHotaComponent()
313 HotaGetHash(hashOut, HASH_LENGTH); in ParseHotaComponent()
322 …if (memcmp(hashOut, g_componentInfos.table[g_currentDloadComp.index - 1].shaData, HASH_LENGTH) != … in ParseHotaComponent()
/base/account/os_account/services/accountmgr/src/
Dohos_account_manager.cpp46 constexpr std::uint32_t HASH_LENGTH = 32; variable
47 constexpr std::uint32_t OHOS_ACCOUNT_UDID_LENGTH = HASH_LENGTH * 2;
76 unsigned char hash[HASH_LENGTH] = { 0 }; in GenerateOhosUdidWithSha256()
87 for (std::uint32_t i = 0; i < HASH_LENGTH; ++i) { in GenerateOhosUdidWithSha256()
/base/startup/init/simulator/parameter/src/
Dparameter_common.c32 #define HASH_LENGTH 32 macro