Home
last modified time | relevance | path

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

/base/security/device_security_level/baselib/utils/src/
Dutils_base64.c179 int realLen = Base64Encode(from, fromLen, out, outSize); in Base64EncodeApp() local
180 if (realLen < 0) { in Base64EncodeApp()
185 out[realLen] = '\0'; in Base64EncodeApp()
208 int realLen = Base64Decode(src, decoded, decodedLen); in Base64DecodeApp() local
209 if (realLen < 0) { in Base64DecodeApp()
215 decoded[realLen] = '\0'; in Base64DecodeApp()
217 return realLen; in Base64DecodeApp()
/base/startup/appspawn/modules/sandbox/
Dsandbox_cfgvar.c26 const char *buffer, uint32_t bufferLen, uint32_t *realLen, const VarExtraData *extraData) in VarPackageNameIndexReplace() argument
40 *realLen = (uint32_t)len; in VarPackageNameIndexReplace()
45 const char *buffer, uint32_t bufferLen, uint32_t *realLen, const VarExtraData *extraData) in VarPackageNameReplace() argument
50 *realLen = (uint32_t)len; in VarPackageNameReplace()
55 const char *buffer, uint32_t bufferLen, uint32_t *realLen, const VarExtraData *extraData) in VarCurrentUseIdReplace() argument
70 *realLen = (uint32_t)len; in VarCurrentUseIdReplace()
101 const char *buffer, uint32_t bufferLen, uint32_t *realLen, const VarExtraData *extraData) in ReplaceVariableForDepSandboxPath() argument
107 *realLen = len; in ReplaceVariableForDepSandboxPath()
112 const char *buffer, uint32_t bufferLen, uint32_t *realLen, const VarExtraData *extraData) in ReplaceVariableForDepSrcPath() argument
118 *realLen = len; in ReplaceVariableForDepSrcPath()
[all …]
/base/startup/init/services/param/base/
Dparam_trie.c244 … uint32_t realLen = PARAM_ALIGN(sizeof(ParamSecurityNode) + sizeof(uid_t) * auditData->memberNum); in AddParamSecurityNode() local
245 PARAM_CHECK((workSpace->area->currOffset + realLen) < workSpace->area->dataSize, in AddParamSecurityNode()
247 workSpace->area->currOffset, workSpace->area->dataSize, realLen); in AddParamSecurityNode()
261realLen - sizeof(ParamSecurityNode), auditData->members, auditData->memberNum * sizeof(uid_t)); in AddParamSecurityNode()
266 workSpace->area->currOffset += realLen; in AddParamSecurityNode()
277 uint32_t realLen = sizeof(ParamNode) + 1 + 1; in AddParamNode() local
280 realLen += keyLen + valueLen; in AddParamNode()
282 realLen += keyLen + GetParamMaxLen(type); in AddParamNode()
284 realLen = PARAM_ALIGN(realLen); in AddParamNode()
285 PARAM_CHECK((workSpace->area->currOffset + realLen) < workSpace->area->dataSize, in AddParamNode()
[all …]
Dparam_base.c134 uint32_t realLen = PARAM_ALIGN(sizeof(WorkSpaceSize) + sizeof(uint32_t) * maxLabel); in AllocSpaceMemory() local
135 PARAM_CHECK((workSpace->area->currOffset + realLen) < workSpace->area->dataSize, return 0, in AllocSpaceMemory()
137 workSpace->area->currOffset, workSpace->area->dataSize, realLen); in AllocSpaceMemory()
150 workSpace->area->currOffset += realLen; in AllocSpaceMemory()
/base/startup/init/services/begetctl/
Dparam_cmd.c82 int32_t realLen = 0; in GetRealParameter() local
88 realLen = tmp - current; in GetRealParameter()
89 ret = memcpy_s(buffer, buffSize, current, realLen); in GetRealParameter()
92 realLen = 1; in GetRealParameter()
96 realLen = sprintf_s(buffer, buffSize, "%s", current); in GetRealParameter()
98 realLen = sprintf_s(buffer, buffSize, "%s%s", current, name); in GetRealParameter()
101 realLen = sprintf_s(buffer, buffSize, "%s", current); in GetRealParameter()
103 realLen = sprintf_s(buffer, buffSize, "%s", name); in GetRealParameter()
105 BSH_CHECK(realLen >= 0, return NULL, "Failed to format buffer"); in GetRealParameter()
106 buffer[realLen] = '\0'; in GetRealParameter()
/base/startup/appspawn/interfaces/innerkits_new/client/
Dappspawn_msg.c73 static AppSpawnMsgBlock *GetValidMsgBlock(const AppSpawnReqMsgNode *reqNode, uint32_t realLen) in GetValidMsgBlock() argument
79 if ((block->blockSize - block->currentIndex) >= realLen) { in GetValidMsgBlock()
130 uint32_t realLen = APPSPAWN_ALIGN(reminderDataLen); in AddAppDataToTail() local
132 if (reminderBufferLen >= realLen) { // 足够存储,直接保存 in AddAppDataToTail()
135 block->currentIndex += realLen; in AddAppDataToTail()
192 uint32_t realLen = sizeof(AppSpawnTlv); in AddAppData() local
196 realLen += (data[index].dataType == DATA_TYPE_STRING) ? in AddAppData()
200 tlv.tlvLen = realLen; in AddAppData()
/base/startup/appspawn/test/unittest/
Dapp_spawn_test_helper.cpp570 uint32_t realLen = 0; in CreateSendMsg() local
572 int ret = addTlvFunc(buffer.data() + currLen, buffer.size() - currLen, realLen, tlvCount); in CreateSendMsg()
573 APPSPAWN_CHECK(ret == 0 && (currLen + realLen) < buffer.size(), in CreateSendMsg()
575 msg->msgLen += realLen; in CreateSendMsg()
576 currLen += realLen; in CreateSendMsg()
607 int AppSpawnTestHelper::AddBaseTlv(uint8_t *buffer, uint32_t bufferLen, uint32_t &realLen, uint32_t… in AddBaseTlv() argument
650 realLen = currLen; in AddBaseTlv()
Dapp_spawn_test_helper.h52 using AddTlvFunction = std::function<int(uint8_t *buffer, uint32_t bufferLen, uint32_t &realLen, ui…
116 … static int AddBaseTlv(uint8_t *buffer, uint32_t bufferLen, uint32_t &realLen, uint32_t &tlvCount);
/base/update/updater/services/package/pkg_package/
Dpkg_pkgfile.cpp123 …eImpl::ConvertStringToBuffer(const std::string &fileName, const PkgBuffer &buffer, size_t &realLen) in ConvertStringToBuffer() argument
131 (realLen)++; in ConvertStringToBuffer()
Dpkg_pkgfile.h84 …t32_t ConvertStringToBuffer(const std::string &fileName, const PkgBuffer &buffer, size_t &realLen);
Dpkg_zipfile.cpp371 size_t realLen = 0; in EncodeCentralDirEntry() local
374 }, realLen); in EncodeCentralDirEntry()
392 centralDir->nameSize = realLen; in EncodeCentralDirEntry()
400 int32_t ret = stream->Write(buffer, sizeof(CentralDirEntry) + realLen, startOffset); in EncodeCentralDirEntry()
405 encodeLen = sizeof(CentralDirEntry) + realLen; in EncodeCentralDirEntry()
Dpkg_upgradefile.cpp715 int32_t UpgradePkgFile::ReadUpgradePkgHeader(size_t &realLen, DigestAlgorithm::DigestAlgorithmPtr &… in ReadUpgradePkgHeader() argument
740 realLen = currLen + tlv.length; in ReadUpgradePkgHeader()
741 algorithm->Update(buffer, realLen); in ReadUpgradePkgHeader()
742 ret = pkgStream_->Read(buffer, realLen, buffer.length, readLen); in ReadUpgradePkgHeader()
761 realLen += currLen; in ReadUpgradePkgHeader()
Dpkg_upgradefile.h164 int32_t ReadUpgradePkgHeader(size_t &realLen,
/base/startup/appspawn/modules/module_engine/include/
Dappspawn_hook.h180 const char *buffer, uint32_t bufferLen, uint32_t *realLen, const VarExtraData *extraData);
/base/startup/appspawn/test/unittest/app_spawn_standard_test/
Dapp_spawn_appmgr_test.cpp455 static int AddRenderTerminationTlv(uint8_t *buffer, uint32_t bufferLen, uint32_t &realLen, uint32_t… in AddRenderTerminationTlv() argument
470 realLen = currLen; in AddRenderTerminationTlv()
660 static int AddTest001ExtTlv(uint8_t *buffer, uint32_t bufferLen, uint32_t &realLen, uint32_t &tlvCo… in AddTest001ExtTlv() argument
677 realLen = currLen; in AddTest001ExtTlv()
Dapp_spawn_sandboxmgr_test.cpp603 const char *buffer, uint32_t bufferLen, uint32_t *realLen, const VarExtraData *extraData) in TestReplaceVarHandler() argument
Dapp_spawn_sandbox_new_test.cpp515 const char *buffer, uint32_t bufferLen, uint32_t *realLen, const VarExtraData *extraData) in TestVariableReplace() argument
520 *realLen = (uint32_t)len; in TestVariableReplace()