Home
last modified time | relevance | path

Searched refs:comp (Results 1 – 14 of 14) sorted by relevance

/base/security/security_component_manager/services/security_component_service/sa/sa_main/
Dsec_comp_info_helper.cpp40 SecCompBase* comp = nullptr; in ParseComponent() local
43 comp = ConstructComponent<LocationButton>(jsonComponent); in ParseComponent()
46 comp = ConstructComponent<PasteButton>(jsonComponent); in ParseComponent()
49 comp = ConstructComponent<SaveButton>(jsonComponent); in ParseComponent()
55 if (comp == nullptr) { in ParseComponent()
57 return comp; in ParseComponent()
60 comp->SetValid(CheckComponentValid(comp)); in ParseComponent()
61 return comp; in ParseComponent()
127 static bool CheckSecCompBaseButton(const SecCompBase* comp) in CheckSecCompBaseButton() argument
129 if ((comp->text_ < 0) && (comp->icon_ < 0)) { in CheckSecCompBaseButton()
[all …]
Dsec_comp_info_helper.h45 static bool CheckComponentValid(const SecCompBase* comp);
/base/security/security_component_manager/services/security_component_service/sa/test/unittest/src/
Dsec_comp_info_helper_test.cpp87 SecCompBase* comp = SecCompInfoHelper::ParseComponent(LOCATION_COMPONENT, jsonComponent); variable
88 ASSERT_NE(nullptr, comp);
89 ASSERT_TRUE(comp->GetValid());
119 SecCompBase* comp = SecCompInfoHelper::ParseComponent(LOCATION_COMPONENT, jsonComponent); variable
120 ASSERT_TRUE(comp->GetValid());
123 comp = SecCompInfoHelper::ParseComponent(LOCATION_COMPONENT, jsonComponent);
124 ASSERT_EQ(nullptr, comp);
229 SecCompBase* comp = SecCompInfoHelper::ParseComponent(LOCATION_COMPONENT, jsonComponent); variable
230 ASSERT_TRUE(comp->GetValid());
235 comp = SecCompInfoHelper::ParseComponent(LOCATION_COMPONENT, jsonComponent);
[all …]
/base/update/updater/test/unittest/updater_binary/
Dupdater_binary_unittest.cpp145 ComponentInfoExt *comp = (ComponentInfoExt*)malloc( in CreatePackageBin() local
147 if (comp == nullptr) { in CreatePackageBin()
151 BuildCompnentInfo(comp[i], testFileNames_[i], testFileNames_[i], componentType); in CreatePackageBin()
155 BuildCompnentInfo(comp[index++], "/hos"); in CreatePackageBin()
156 BuildCompnentInfo(comp[index++], "/system"); in CreatePackageBin()
157 BuildCompnentInfo(comp[index++], "/vendor"); in CreatePackageBin()
161 ret = CreatePackage(&pkgInfo, comp, packagePath.c_str(), GetTestPrivateKeyName().c_str()); in CreatePackageBin()
163 free(comp[i].componentAddr); in CreatePackageBin()
164 free(comp[i].filePath); in CreatePackageBin()
165 free(comp[i].version); in CreatePackageBin()
[all …]
/base/security/security_component_manager/interfaces/inner_api/security_component/test/unittest/src/
Dsec_comp_kit_test.cpp91 LocationButton comp; variable
92 comp.fontSize_ = TestCommon::TEST_SIZE;
93 comp.iconSize_ = TestCommon::TEST_SIZE;
94 comp.padding_.top = TestCommon::TEST_DIMENSION;
95 comp.padding_.right = TestCommon::TEST_DIMENSION;
96 comp.padding_.bottom = TestCommon::TEST_DIMENSION;
97 comp.padding_.left = TestCommon::TEST_DIMENSION;
98 comp.textIconSpace_ = TestCommon::TEST_SIZE;
99 comp.bgColor_.value = TestCommon::TEST_COLOR;
100 comp.fontColor_.value = TestCommon::TEST_COLOR;
[all …]
Dlocation_button_test.cpp56 LocationButton comp; variable
57 ASSERT_TRUE(comp.FromJson(jsonComponent));
69 LocationButton comp; variable
70 ASSERT_FALSE(comp.FromJson(jsonComponent));
83 LocationButton comp; variable
84 ASSERT_TRUE(comp.FromJson(jsonComponent));
87 ASSERT_FALSE(comp.FromJson(jsonComponent));
90 ASSERT_FALSE(comp.FromJson(jsonComponent));
102 LocationButton comp; variable
106 ASSERT_FALSE(comp.FromJson(jsonComponent));
[all …]
/base/update/sys_installer/test/fuzztest/
Dsys_installer_fuzzer.cpp113 ComponentInfoExt comp[fstabFile.size()]; in CreatePackageZip() local
115 comp[i].componentAddr = strdup(fstabFile[i].c_str()); in CreatePackageZip()
118 comp[i].filePath = strdup(filePath.c_str()); in CreatePackageZip()
119 comp[i].version = strdup("55555555"); in CreatePackageZip()
121 ret = BuildFileDigest(*comp[i].digest, sizeof(comp[i].digest), filePath); in CreatePackageZip()
122 comp[i].size = GetFileSize(filePath); in CreatePackageZip()
123 comp[i].originalSize = comp[i].size; in CreatePackageZip()
124 comp[i].id = componentInfoIdBase; in CreatePackageZip()
125 comp[i].resType = 1; in CreatePackageZip()
126 comp[i].type = 1; in CreatePackageZip()
[all …]
/base/update/updater/test/fuzztest/UpdaterStartUpdaterProc_fuzzer/
DUpdaterStartUpdaterProc_fuzzer.cpp123 ComponentInfoExt comp[fstabFile.size()]; in CreatePackageZip() local
125 comp[i].componentAddr = strdup(fstabFile[i].c_str()); in CreatePackageZip()
128 comp[i].filePath = strdup(filePath.c_str()); in CreatePackageZip()
129 comp[i].version = strdup("55555555"); in CreatePackageZip()
131 ret = BuildFileDigest(*comp[i].digest, sizeof(comp[i].digest), filePath); in CreatePackageZip()
132 comp[i].size = GetFileSize(filePath); in CreatePackageZip()
133 comp[i].originalSize = comp[i].size; in CreatePackageZip()
134 comp[i].id = componentInfoIdBase; in CreatePackageZip()
135 comp[i].resType = 1; in CreatePackageZip()
136 comp[i].type = 1; in CreatePackageZip()
[all …]
/base/update/updater/test/fuzztest/extractandexecutescript_fuzzer/
Dextractandexecutescript_fuzzer.cpp251 ComponentInfoExt comp[inputFile.size()]; in CreatePackageBin() local
253 comp[i].componentAddr = strdup(inputFile[i].c_str()); in CreatePackageBin()
256 comp[i].filePath = strdup(filePath.c_str()); in CreatePackageBin()
257 comp[i].version = strdup("55555555"); in CreatePackageBin()
259 ret = BuildFileDigest(*comp[i].digest, sizeof(comp[i].digest), filePath); in CreatePackageBin()
260 comp[i].size = GetFileSize(filePath); in CreatePackageBin()
261 comp[i].originalSize = comp[i].size; in CreatePackageBin()
262 comp[i].id = componentInfoIdBase; in CreatePackageBin()
263 comp[i].resType = 1; in CreatePackageBin()
264 comp[i].type = 1; in CreatePackageBin()
[all …]
/base/update/updater/test/unittest/package/
Dpackage_unittest.cpp101 ComponentInfoExt comp[testFileNames_.size()]; in TestPackagePack() local
103 comp[i].componentAddr = strdup(testFileNames_[i].c_str()); in TestPackagePack()
106 comp[i].filePath = strdup(filePath.c_str()); in TestPackagePack()
107 comp[i].version = strdup("55555555"); in TestPackagePack()
108 ret = BuildFileDigest(*comp[i].digest, sizeof(comp[i].digest), filePath); in TestPackagePack()
110 comp[i].size = GetFileSize(filePath); in TestPackagePack()
111 comp[i].originalSize = comp[i].size; in TestPackagePack()
112 comp[i].id = i + componentIdBase; in TestPackagePack()
113 comp[i].resType = 1; in TestPackagePack()
114 comp[i].type = 1; in TestPackagePack()
[all …]
/base/update/updater/services/package/pkg_package/
Dpkg_upgradefile.cpp763 int32_t UpgradeFileEntry::GetUpGradeCompInfo(UpgradeCompInfo &comp) in GetUpGradeCompInfo() argument
765 if (memset_s(&comp, sizeof(comp), 0, sizeof(comp)) != EOK) { in GetUpGradeCompInfo()
771 fileInfo_.fileInfo.identity, {comp.address, sizeof(comp.address)}, len); in GetUpGradeCompInfo()
777 …ret = PkgFileImpl::ConvertStringToBuffer(fileInfo_.version, {comp.version, sizeof(comp.version)}, … in GetUpGradeCompInfo()
782 ret = memcpy_s(comp.digest, sizeof(comp.digest), fileInfo_.digest, sizeof(fileInfo_.digest)); in GetUpGradeCompInfo()
798 UpgradeCompInfo comp; in EncodeHeader() local
799 int ret = GetUpGradeCompInfo(comp); in EncodeHeader()
805 WriteLE32(reinterpret_cast<uint8_t *>(&comp.size), fileInfo_.fileInfo.unpackedSize); in EncodeHeader()
806 WriteLE16(reinterpret_cast<uint8_t *>(&comp.id), fileInfo_.id); in EncodeHeader()
807 WriteLE32(reinterpret_cast<uint8_t *>(&comp.originalSize), fileInfo_.originalSize); in EncodeHeader()
[all …]
Dpkg_upgradefile.h90 int32_t GetUpGradeCompInfo(UpgradeCompInfo &comp);
/base/hiviewdfx/hiview/base/include/
Devent_priority_queue.h31 std::make_heap(this->c.begin(), this->c.end(), this->comp); in remove()
/base/update/updater/interfaces/kits/include/package/
Dpackage.h110 int32_t CreatePackage(const UpgradePkgInfoExt *pkgInfo, ComponentInfoExt comp[],