/base/startup/init/services/begetctl/ |
D | param_cmd.c | 56 static char *GetLocalBuffer(uint32_t *buffSize) in GetLocalBuffer() argument 59 BEGET_CHECK(buffSize == NULL, *buffSize = sizeof(buffer)); in GetLocalBuffer() 63 static char *GetRealParameter(BShellHandle shell, const char *name, char *buffer, uint32_t buffSize) in GetRealParameter() argument 75 ret = memcpy_s(buffer, buffSize, current, realLen); in GetRealParameter() 77 ret = memcpy_s(buffer, buffSize, "#", 1); in GetRealParameter() 82 realLen = sprintf_s(buffer, buffSize, "%s", current); in GetRealParameter() 84 realLen = sprintf_s(buffer, buffSize, "%s%s", current, name); in GetRealParameter() 87 realLen = sprintf_s(buffer, buffSize, "%s", current); in GetRealParameter() 89 realLen = sprintf_s(buffer, buffSize, "%s", name); in GetRealParameter() 99 uint32_t buffSize = 0; in SetParamShellPrompt() local [all …]
|
/base/startup/init/test/moduletest/ |
D | param_test_cmds.c | 34 static char *GetLocalBuffer(uint32_t *buffSize) in GetLocalBuffer() argument 37 if (buffSize != NULL) { in GetLocalBuffer() 38 *buffSize = sizeof(buffer); in GetLocalBuffer() 47 uint32_t buffSize = 0; in CmdReader() local 48 char *buffer = GetLocalBuffer(&buffSize); in CmdReader() 51 uint32_t size = buffSize; in CmdReader() 208 uint32_t buffSize = 0; in BShellParamCmdWatch() local 209 char *buffer = GetLocalBuffer(&buffSize); in BShellParamCmdWatch() 212 int len = sprintf_s(buffer, buffSize, "%s.%zu", argv[1], count); in BShellParamCmdWatch() 225 uint32_t buffSize = 0; in BShellParamCmdInstall() local [all …]
|
/base/security/device_security_level/baselib/utils/src/ |
D | utils_tlv.c | 70 …e(const TlvCommon *tlv, uint32_t tlvCount, uint8_t *buff, uint32_t maxBuffSize, uint32_t *buffSize) in Serialize() argument 72 if (tlv == NULL || buff == NULL || buffSize == NULL) { in Serialize() 86 *buffSize = curr - buff; in Serialize() 90 uint32_t Deserialize(const uint8_t *buff, uint32_t buffSize, TlvCommon *tlv, uint32_t maxTlvCount, … in Deserialize() argument 97 const uint8_t *boundary = buff + buffSize; in Deserialize()
|
/base/security/device_security_level/baselib/utils/include/ |
D | utils_tlv.h | 37 …(const TlvCommon *tlv, uint32_t tlvCount, uint8_t *buff, uint32_t maxBuffSize, uint32_t *buffSize); 39 uint32_t Deserialize(const uint8_t *buff, uint32_t buffSize, TlvCommon *tlv, uint32_t maxTlvCount, …
|
/base/startup/init/ueventd/ |
D | ueventd_socket.c | 31 int buffSize = UEVENT_SOCKET_BUFF_SIZE; in UeventdSocketInit() local 48 setsockopt(sockfd, SOL_SOCKET, SO_RCVBUFFORCE, &buffSize, sizeof(buffSize)); in UeventdSocketInit()
|
/base/startup/init/services/param/adapter/ |
D | param_persistadp.c | 49 const int buffSize = PARAM_NAME_LEN_MAX + PARAM_CONST_VALUE_LEN_MAX + 10; // 10 max len in LoadPersistParam() local 50 char *buffer = malloc(buffSize); in LoadPersistParam() 56 while (fgets(buffer, buffSize, fp) != NULL) { in LoadPersistParam() 57 buffer[buffSize - 1] = '\0'; in LoadPersistParam()
|
D | param_dac.c | 144 const uint32_t buffSize = PARAM_NAME_LEN_MAX + PARAM_CONST_VALUE_LEN_MAX + 10; // 10 size in LoadParamLabels() local 145 char *buff = (char *)calloc(1, buffSize); in LoadParamLabels() 146 while (fp != NULL && buff != NULL && fgets(buff, buffSize, fp) != NULL) { in LoadParamLabels() 147 buff[buffSize - 1] = '\0'; in LoadParamLabels() 352 const uint32_t buffSize = 1024; // 1024 max buffer for decode in LoadGroupUser_() local 353 char *buff = (char *)calloc(1, buffSize); in LoadGroupUser_() 354 while (fp != NULL && buff != NULL && fgets(buff, buffSize, fp) != NULL) { in LoadGroupUser_() 355 buff[buffSize - 1] = '\0'; in LoadGroupUser_()
|
/base/useriam/user_auth_framework/common/utils/ |
D | iam_time.cpp | 32 constexpr uint32_t buffSize = 64; in GetNowTimeString() local 38 char timeStr[buffSize + 1] = {0}; in GetNowTimeString()
|
/base/security/certificate_manager/test/unittest/src/ |
D | cm_app_cert_test.cpp | 395 uint32_t buffSize = MAX_COUNT_CERTIFICATE * sizeof(struct CredentialAbstract); variable 396 … certificateList.credentialAbstract = static_cast<struct CredentialAbstract *>(CmMalloc(buffSize)); 402 (void)memset_s(certificateList.credentialAbstract, buffSize, 0, buffSize); 430 uint32_t buffSize = MAX_COUNT_CERTIFICATE * sizeof(struct CredentialAbstract); variable 431 … certificateList.credentialAbstract = static_cast<struct CredentialAbstract *>(CmMalloc(buffSize)); 434 (void)memset_s(certificateList.credentialAbstract, buffSize, 0, buffSize); 471 uint32_t buffSize = MAX_COUNT_CERTIFICATE * sizeof(struct CredentialAbstract); variable 472 … certificateList.credentialAbstract = static_cast<struct CredentialAbstract *>(CmMalloc(buffSize)); 475 (void)memset_s(certificateList.credentialAbstract, buffSize, 0, buffSize);
|
D | cm_test_common.cpp | 75 uint32_t buffSize = MAX_COUNT_CERTIFICATE * sizeof(struct CertAbstract); in InitCertList() local 76 (*cList)->certAbstract = static_cast<struct CertAbstract *>(CmMalloc(buffSize)); in InitCertList() 80 (void)memset_s((*cList)->certAbstract, buffSize, 0, buffSize); in InitCertList()
|
/base/update/ota_lite/frameworks/source/updater/ |
D | hota_updater.c | 421 static int CopyToDloadCompBuffer(const unsigned char *buffer, unsigned int buffSize) in CopyToDloadCompBuffer() argument 423 if (g_currentDloadComp.currentSize + buffSize > MAX_BUFFER_SIZE) { in CopyToDloadCompBuffer() 429 buffer, buffSize) != EOK) { in CopyToDloadCompBuffer() 509 static int HotaDefaultWrite(unsigned char *buffer, unsigned int offset, unsigned int buffSize) in HotaDefaultWrite() argument 511 if ((buffer == NULL) || (buffSize == 0) || (buffSize > MAX_TRANSPORT_BUFF_SIZE)) { in HotaDefaultWrite() 512 … printf("Param is illegal. buffer is NULL or buffSize too big. buffsize = %u.\r\n", buffSize); in HotaDefaultWrite() 523 unsigned int tempBuffSize = buffSize; in HotaDefaultWrite() 620 int HotaWrite(unsigned char *buffer, unsigned int offset, unsigned int buffSize) in HotaWrite() argument 623 return HotaHalWrite(0, buffer, offset, buffSize); in HotaWrite() 626 return HotaDefaultWrite(buffer, offset, buffSize); in HotaWrite()
|
/base/security/certificate_manager/services/cert_manager_standard/cert_manager_service/main/os_dependency/idl/cm_ipc/ |
D | cm_ipc_service_serialization.c | 125 …uint32_t buffSize = sizeof(uint32_t) + (sizeof(uint32_t) + MAX_LEN_SUBJECT_NAME + sizeof(uint32_t)… in CmGetCertListPack() local 127 if (certificateList->size < buffSize) { in CmGetCertListPack() 131 certificateList->size = buffSize; in CmGetCertListPack() 196 uint32_t buffSize = sizeof(uint32_t) + MAX_LEN_CERTIFICATE + sizeof(uint32_t) + in CmServiceGetCertInfoPack() local 198 if (certificateInfo->size < buffSize) { in CmServiceGetCertInfoPack() 202 certificateInfo->size = buffSize; in CmServiceGetCertInfoPack()
|
/base/security/certificate_manager/interfaces/kits/napi/src/ |
D | cm_napi_get_app_cert_list_common.cpp | 101 uint32_t buffSize = (MAX_COUNT_CERTIFICATE * sizeof(struct CredentialAbstract)); in InitAppCertList() local 102 … credentialList->credentialAbstract = static_cast<struct CredentialAbstract *>(CmMalloc(buffSize)); in InitAppCertList() 107 (void)memset_s(credentialList->credentialAbstract, buffSize, 0, buffSize); in InitAppCertList()
|
D | cm_napi_get_system_cert_list.cpp | 162 uint32_t buffSize = MAX_COUNT_CERTIFICATE * sizeof(struct CertAbstract); in GetCertListExecute() local 163 context->certificateList->certAbstract = static_cast<struct CertAbstract *>(CmMalloc(buffSize)); in GetCertListExecute() 169 (void)memset_s(context->certificateList->certAbstract, buffSize, 0, buffSize); in GetCertListExecute()
|
/base/startup/init/services/loopevent/task/ |
D | le_task.c | 82 buffer->buffSize = bufferSize; in CreateBuffer() 157 uint8_t *LE_GetBufferInfo(const BufferHandle handle, uint32_t *dataSize, uint32_t *buffSize) in LE_GetBufferInfo() argument 164 if (buffSize) { in LE_GetBufferInfo() 165 *buffSize = (uint32_t)buffer->buffSize; in LE_GetBufferInfo()
|
/base/hiviewdfx/hilog/services/hilogd/ |
D | log_buffer.cpp | 338 uint64_t buffSize = g_maxBufferSizeByType[logType]; in GetBuffLen() local 339 return buffSize; in GetBuffLen() 342 int32_t HilogBuffer::SetBuffLen(uint16_t logType, uint64_t buffSize) in SetBuffLen() argument 347 if (buffSize < MIN_BUFFER_SIZE || buffSize > MAX_BUFFER_SIZE) { in SetBuffLen() 351 g_maxBufferSizeByType[logType] = buffSize; in SetBuffLen()
|
/base/startup/init/services/param/base/ |
D | param_base.h | 31 INIT_LOCAL_API int ParamSprintf(char *buffer, size_t buffSize, const char *format, ...);
|
/base/update/updater/services/package/pkg_package/ |
D | pkg_upgradefile.cpp | 122 size_t buffSize = GetUpgradeSignatureLen() + UPGRADE_RESERVE_LEN; in SavePackage() local 123 buffSize = ((UPGRADE_FILE_HEADER_LEN > buffSize) ? UPGRADE_FILE_HEADER_LEN : buffSize); in SavePackage() 124 std::vector<uint8_t> buffer(buffSize); in SavePackage() 183 size_t buffSize = UPGRADE_FILE_HEADER_LEN + sizeof(UpgradeCompInfo) + in LoadPackage() local 185 PKG_CHECK(fileLen > 0 && fileLen >= buffSize, in LoadPackage() 190 PkgBuffer buffer(buffSize); in LoadPackage() 228 size_t buffSize = BUFFER_SIZE; in Verify() local 231 PkgBuffer buffer(buffSize); in Verify() 237 remainBytes = ((remainBytes > buffSize) ? buffSize : remainBytes); in Verify()
|
/base/startup/init/services/param/manager/ |
D | param_server.c | 171 const int buffSize = PARAM_NAME_LEN_MAX + PARAM_CONST_VALUE_LEN_MAX + 10; // 10 max len in LoadDefaultParam_() local 172 char *buffer = malloc(buffSize); in LoadDefaultParam_() 177 while (fgets(buffer, buffSize, fp) != NULL) { in LoadDefaultParam_() 178 buffer[buffSize - 1] = '\0'; in LoadDefaultParam_()
|
/base/security/certificate_manager/frameworks/cert_manager_standard/main/os_dependency/cm_ipc/src/ |
D | cm_ipc_client.c | 43 …uint32_t buffSize = sizeof(uint32_t) + (sizeof(uint32_t) + MAX_LEN_SUBJECT_NAME + sizeof(uint32_t)… in GetCertListInitOutData() local 45 outListBlob->data = (uint8_t *)CmMalloc(buffSize); in GetCertListInitOutData() 49 outListBlob->size = buffSize; in GetCertListInitOutData() 100 uint32_t buffSize = sizeof(uint32_t) + MAX_LEN_CERTIFICATE + sizeof(uint32_t) + in GetCertInfoInitOutData() local 103 outInfoBlob->data = (uint8_t *)CmMalloc(buffSize); in GetCertInfoInitOutData() 107 outInfoBlob->size = buffSize; in GetCertInfoInitOutData() 298 …uint32_t buffSize = sizeof(uint32_t) + (sizeof(uint32_t) + MAX_LEN_SUBJECT_NAME + sizeof(uint32_t)… in GetAppCertListInitBlob() local 300 outBlob->data = (uint8_t *)CmMalloc(buffSize); in GetAppCertListInitBlob() 304 outBlob->size = buffSize; in GetAppCertListInitBlob() 437 uint32_t buffSize = sizeof(uint32_t) + sizeof(uint32_t) + MAX_LEN_SUBJECT_NAME + in GetAppCertInitBlob() local [all …]
|
/base/update/ota_lite/interfaces/kits/ |
D | hota_updater.h | 129 int HotaWrite(unsigned char *buffer, unsigned int offset, unsigned int buffSize);
|
/base/update/updater/test/unittest/updater_binary/ |
D | updater_binary_unittest.cpp | 85 size_t buffSize = 4096; in BuildFileDigest() local 86 PkgBuffer buff(buffSize); in BuildFileDigest() 96 ret = stream->Read(buff, offset, buffSize, readLen); in BuildFileDigest()
|
/base/update/updater/test/fuzztest/UpdaterStartUpdaterProc_fuzzer/ |
D | UpdaterStartUpdaterProc_fuzzer.cpp | 62 size_t buffSize = 4096; in BuildFileDigest() local 63 PkgBuffer buff(buffSize); in BuildFileDigest() 73 ret = stream->Read(buff, offset, buffSize, readLen); in BuildFileDigest()
|
/base/update/updater/test/unittest/package/ |
D | pkg_test.h | 81 size_t buffSize = 4096; in BuildFileDigest() local 82 Hpackage::PkgBuffer buff(buffSize); in BuildFileDigest() 92 ret = stream->Read(buff, offset, buffSize, readLen); in BuildFileDigest()
|
/base/startup/init/services/init/ |
D | init_service_socket.c | 84 int buffSize = SOCKET_BUFF_SIZE; in SetSocketOptionAndBind() local 85 if (setsockopt(sockopt->sockFd, SOL_SOCKET, SO_RCVBUFFORCE, &buffSize, sizeof(buffSize))) { in SetSocketOptionAndBind()
|