Home
last modified time | relevance | path

Searched full:hap (Results 1 – 25 of 226) sorted by relevance

12345678910

/developtools/packing_tool/adapter/ohos/
DREADME16 use commands for package hap or app.
19 1.When the app depends on a hap, you need to wait the hap has been packaged,
22 For example: --mode hap --mode app
25 For example: --mode hap app
26 the mode value is hap.
31 7.After package a hap, files under resources/ will put into assets/entry/resources/ directory,
41 HAP USAGE:
46 HAP MODE OPTIONS:
47 --mode not null must be hap.
66 --out-path not null target hap binary path,must end with .hap.
[all …]
DUncompressEntrance.java34 * Parses and returns the hap list that supports the device type.
36 public static final String PARSE_MODE_HAPLIST = "hap-list";
39 * Parses and returns the information about the hap.
41 public static final String PARSE_MODE_HAPINFO = "hap-info";
44 …* Parses and returns the informations about the hap list that supports the device type and the hap…
90 private static final String HAP_SUFFIX = ".hap";
102 HAP_LIST(1, "hap-list"),
103 HAP_INFO(2, "hap-info");
136 …* @param unpackApk Indicates whether to decompress the apk file in the hap.The default value is {@…
173 * Unpack the hap.
[all …]
DShowHelp.java34 " --mode not null must be hap.\n" + in compressHelp()
51 " --out-path not null target hap binary path, must end with .hap.\n" + in compressHelp()
76 "java -jar app_packing_tool.jar --mode <options> --hap-path <option>\n" + in compressHelp()
81 " --hap-path not null 1.hap path must end with .hap,\n" + in compressHelp()
82 … " if has more than one hap, use comma(,) to separate;\n" + in compressHelp()
83 " 2.hap path also can be directory path.\n" + in compressHelp()
98 "java -jar app_unpacking_tool.jar --mode <options> --hap-path <option>\n" + in uncompressHelp()
101 " --mode not null must be hap.\n" + in uncompressHelp()
102 " --hap-path not null hap path.\n" + in uncompressHelp()
106 … " --unpackapk default false; if true, unpack apk files from hap\n" + in uncompressHelp()
[all …]
DUncompressVerify.java26 private static final String HAP_SUFFIX = ".hap";
73 * parse and check args if valid in hap mode.
76 * @return isVerifyValidInHapMode if verify valid in hap mode.
82 LOG.error("UncompressVerify::isArgsValidInHapMode hap-path must end with.hap!"); in hapCommandVerify()
123 * parse and check args if valid in hap mode.
126 * @return isVerifyValidInRpcidMode if verify valid in hap mode.
138 * parse and check args if valid in hap or hsp mode.
141 * @return isVerifyValidInLibsMode if verify valid in hap or hsp mode.
170 * @return isVerifyValidInHapMode if verify valid in hap mode.
234 * @return isVerifyValidInHapMode if verify valid in hap mode.
[all …]
DHapZipInfo.java21 * Hap zip info
86 * Get hap file name.
88 * @return hap file name.
95 * Set hap file name.
97 * @param hapFileName Indicates the hap file name.
DCompressEntrance.java29 private static final String HAP_SUFFIX = ".hap";
35 * @param hapPath Indicates the hap path.
78 * get sha-256 from hap path.
80 * @param hapPath Indicates the hap path.
81 * @return Returns the string of sha-256 for hap.
85 LOG.error("input file is not a hap."); in getHapSha256()
/developtools/hapsigner/hapsigntool_cpp_test/unittest/codeSigning/sign/
Dverify_code_signature_test.cpp42 …d)rename("./codeSigning/hap_profile_is_null_err.txt", "./codeSigning/hap_profile_is_null_err.hap"); in SetUpTestCase()
43 …./codeSigning/hap_invalid_block_header_err.txt", "./codeSigning/hap_invalid_block_header_err.hap"); in SetUpTestCase()
44 … (void)rename("./codeSigning/hap_offset_align_err.txt", "./codeSigning/hap_offset_align_err.hap"); in SetUpTestCase()
45 … (void)rename("./codeSigning/hap_magic_number_err.txt", "./codeSigning/hap_magic_number_err.hap"); in SetUpTestCase()
46 …oid)rename("./codeSigning/hap_segment_header_err.txt", "./codeSigning/hap_segment_header_err.hap"); in SetUpTestCase()
47 …d)rename("./codeSigning/entry-default-signed-so.txt", "./codeSigning/entry-default-signed-so.hap"); in SetUpTestCase()
49 (void)rename("./codeSigning/hap_native_libs_err.txt", "./codeSigning/hap_native_libs_err.hap"); in SetUpTestCase()
109 std::string file = "./codeSigning/entry-default-signed-so.hap";
112 std::string fileFormat = "hap";
123 * @tc.desc: verify hap without profile content
[all …]
Dcode_signing_test.cpp32 …name("./codeSigning/entry-default-unsigned-so.txt", "./codeSigning/entry-default-unsigned-so.hap"); in SetUpTestCase()
34 (void)rename("./codeSigning/unsigned-file.txt", "./codeSigning/unsigned-file.hap"); in SetUpTestCase()
68 params["outFile"] = "./codeSigning/entry-default-signed-so.hap";
72 params["inFile"] = "./codeSigning/entry-default-unsigned-so.hap";
87 options.emplace("outFile", std::string("./codeSigning/entry-default-signed-so.hap"));
94 options.emplace("inFile", std::string("./codeSigning/entry-default-unsigned-so.hap"));
130 params["outFile"] = "./codeSigning/entry-default-signed-so.hap";
134 params["inFile"] = "./codeSigning/entry-default-unsigned-so.hap";
149 options.emplace("outFile", std::string("./codeSigning/entry-default-signed-so.hap"));
156 options.emplace("inFile", std::string("./codeSigning/entry-default-unsigned-so.hap"));
[all …]
Dbc_signeddata_generator_test.cpp35 …name("./codeSigning/entry-default-unsigned-so.txt", "./codeSigning/entry-default-unsigned-so.hap"); in SetUpTestCase()
79 params["outFile"] = "./codeSigning/entry-default-signed-so.hap";
83 params["inFile"] = "./codeSigning/entry-default-unsigned-so.hap";
98 options.emplace("outFile", std::string("./codeSigning/entry-default-signed-so.hap"));
105 options.emplace("inFile", std::string("./codeSigning/entry-default-unsigned-so.hap"));
179 params["outFile"] = "./codeSigning/entry-default-signed-so.hap";
183 params["inFile"] = "./codeSigning/entry-default-unsigned-so.hap";
198 options.emplace("outFile", std::string("./codeSigning/entry-default-signed-so.hap"));
205 options.emplace("inFile", std::string("./codeSigning/entry-default-unsigned-so.hap"));
237 params["outFile"] = "./codeSigning/entry-default-signed-so.hap";
[all …]
/developtools/hapsigner/hapsigntool/hap_sign_tool_lib/src/main/java/com/ohos/hapsigntool/hap/utils/
DHapUtils.java16 package com.ohos.hapsigntool.hap.utils;
19 import com.ohos.hapsigntool.hap.entity.SigningBlock;
47 * Hap util, parse hap, find signature block.
55 * ID of hap signature blocks of version 1
60 * ID of hap proof of rotation block
111 * hap sign schema v2 signature block version
116 * hap sign schema v3 signature block version
141 * Size of hap signature block header
146 * The min size of hap signature block
151 * hap block size
[all …]
/developtools/hapsigner/tools/
Dcommands.config89 …1-profile.p7b" -inFile "test/app1-unsigned.hap" -keystoreFile "ohtest_pass.jks" -outFile "app1-sig…
90 …-profile.p7b" -inFile "test/app1-unsigned.hap" -keystoreFile "ohtest_pass.jks" -outFile "app1-unsi…
91 …1-profile.p7b" -inFile "test/app1-unsigned.hap" -keystoreFile "ohtest_pass.jks" -outFile "app1-sig…
92 …-profile.p7b" -inFile "test/app1-unsigned.hap" -keystoreFile "ohtest_nopass.jks" -outFile "app1-si…
93 …profile.p7b" -inFile "test/app1-unsigned.hap" -keystoreFile "ohtest_nopass.jks" -outFile "app1-uns…
94 …-profile.p7b" -inFile "test/app1-unsigned.hap" -keystoreFile "ohtest_nopass.jks" -outFile "app1-si…
95 …e "profile.json" -keystoreFile "ohtest_pass.jks" -outFile "app1-signedcode.hap" -keyPwd "123456" -…
96 …e "profile.json" -keystoreFile "ohtest_pass.jks" -outFile "app1-signedcode.hap" -keyPwd "123456" -…
97 …e "profile.json" -keystoreFile "ohtest_pass.jks" -outFile "app1-signedcode.hap" -keyPwd "123456" -…
98 …"profile.json" -keystoreFile "ohtest_pass.jks" -outFile "app1-unsignedcode.hap" -keyPwd "123456" -…
[all …]
/developtools/hapsigner/
DREADME.md7 … (CSR), or a certificate, and signing a profile, a Harmony Ability Package (HAP), or a binary tool.
10 …t as required. Currently, hapsigner supports code signing only for apps in hap format and binary t…
40 …3. Check that **hap-sign-tool.jar** (binary files) is generated in the **./hap_sign_tool/target** …
52 Signing tool: hap-sign-tool.jar
68 You can use commands to sign a profile and a HAP or binary tool.
74 java -jar hap-sign-tool.jar sign-profile -keyAlias "oh-profile1-key-v1" -signAlg "SHA256withECDSA"…
91 2. Sign a HAP or binary tool.
95hap-sign-tool.jar sign-app -keyAlias "oh-app1-key-v1" -signAlg "SHA256withECDSA" -mode "localSign"…
99 sign-app: sign a HAP or binary tool
104 …gned provisioning profile in p7b format. This parameter is mandatory for a HAP and optional for a …
[all …]
/developtools/packing_tool/packing_tool/frameworks/src/json/
Dmodule_json_utils.cpp35 const std::string HAP_SUFFIX = ".hap";
54 LOGE("Get hap file length failed! hapFile=%s", hapFilePath.c_str()); in GetStageHapVerifyInfo()
58 LOGE("Get module.json content from hap file failed! hapFile=%s", hapFilePath.c_str()); in GetStageHapVerifyInfo()
62 LOGE("Get resouce map from hap file failed! hapFile=%s", hapFilePath.c_str()); in GetStageHapVerifyInfo()
85 LOGE("Get stage hap verify info failed!"); in GetStageHapVerifyInfo()
96 LOGE("Get hap file length failed! hapFile=%s", hapFilePath.c_str()); in GetFaHapVerifyInfo()
100 LOGE("Get module.json content from hap file failed! hapFile=%s", hapFilePath.c_str()); in GetFaHapVerifyInfo()
109 LOGE("Get FA hap verify info failed!"); in GetFaHapVerifyInfo()
143 LOGE("Hap file path is empty!"); in GetHapVerifyInfosfromFileList()
149 LOGE("Hap file name is empty!"); in GetHapVerifyInfosfromFileList()
[all …]
/developtools/hapsigner/hapsigntool/hap_sign_tool_lib/src/main/java/com/ohos/hapsigntool/hap/verify/
DVerifyHap.java16 package com.ohos.hapsigntool.hap.verify;
24 import com.ohos.hapsigntool.hap.entity.SigningBlock;
29 import com.ohos.hapsigntool.hap.utils.HapUtils;
65 * Class of verify hap.
110 * @param options input parameters used to verify hap.
129 * verify hap file.
131 * @param options input parameters used to verify hap.
148 LOGGER.error("Check input signature hap false!"); in verify()
237 * Verify hap file.
239 * @param hapFilePath path of hap file.
[all …]
/developtools/hapsigner/hapsigntool/hap_sign_tool_lib/src/main/java/com/ohos/hapsigntool/entity/
DParamConstants.java25 * error code of hap format error.
30 * error code of hap parse error.
35 * error code of hap signatures error.
40 * error code of hap signature block not found error.
130 * Hap-file's property, stored developer info
135 * Hap-file's capability profile
140 * json type content of Hap-file's capability profile
145 * Hap-file's proof-of-rotation
240 * The config params of resign hap
250 * The code sign params of resign hap
/developtools/hapsigner/hapsigntool/hap_sign_tool_lib/src/main/java/com/ohos/hapsigntool/hap/sign/
DSignHap.java16 package com.ohos.hapsigntool.hap.sign;
21 import com.ohos.hapsigntool.hap.config.SignerConfig;
23 import com.ohos.hapsigntool.hap.entity.SigningBlock;
25 import com.ohos.hapsigntool.hap.utils.HapUtils;
41 * Hap Signature Scheme signer
62 * Compute digests of Hap contents in getHapSigningBlock()
63 * Sign the digests and wrap the signature and signer info into the Hap Signing Block in getHapSigningBlock()
71 throw new SignatureException("Failed to compute digests of HAP", e); in getHapSigningBlock()
156 result.putLong(resultSize); // length of hap signing block in generateHapSigningBlock()
213 * Signs the provided Hap using Hap Signature Scheme and returns the
[all …]
/developtools/packing_tool/packing_tool/frameworks/test/unittest/app_packager_test/mock/
Dmock_module_json_utils.cpp50 const std::string HAP_SUFFIX = ".hap";
81 LOGE("Get hap file length failed! hapFile=%s", hapFilePath.c_str()); in GetStageHapVerifyInfo()
85 LOGE("Get module.json content from hap file failed! hapFile=%s", hapFilePath.c_str()); in GetStageHapVerifyInfo()
89 LOGE("Get resouce map from hap file failed! hapFile=%s", hapFilePath.c_str()); in GetStageHapVerifyInfo()
102 LOGE("Get stage hap verify info failed!"); in GetStageHapVerifyInfo()
125 LOGE("Get hap file length failed! hapFile=%s", hapFilePath.c_str()); in GetFaHapVerifyInfo()
129 LOGE("Get module.json content from hap file failed! hapFile=%s", hapFilePath.c_str()); in GetFaHapVerifyInfo()
138 LOGE("Get FA hap verify info failed!"); in GetFaHapVerifyInfo()
172 LOGE("Hap file path is empty!"); in GetHapVerifyInfosfromFileList()
178 LOGE("Hap file name is empty!"); in GetHapVerifyInfosfromFileList()
[all …]
/developtools/integration_verification/tools/rom_ram_analyzer/lite_small/src/
Dconfig.yaml45 app: .hap
77 hap: system/internal
93 hap:
112 hap: system/internal
123 hap:
197 hap: app
214 hap:
/developtools/hapsigner/hapsigntool/hap_sign_tool_lib/src/main/java/com/ohos/hapsigntool/codesigning/sign/
DCodeSigning.java38 import com.ohos.hapsigntool.hap.config.SignerConfig;
69 * Only hap and hsp, hqf bundle supports code signing
71 public static final String[] SUPPORT_FILE_FORM = {"hap", "hsp", "hqf"};
79 * Defined entry name of hap file
81 public static final String HAP_SIGNATURE_ENTRY_NAME = "Hap";
92 * provide code sign functions to sign a hap
155 * Sign the given hap file, and pack all signature into output file
160 * @param profileContent profile of the hap
165 * @throws HapFormatException hap format invalid
167 * @throws ProfileException profile of the hap error
[all …]
/developtools/packing_tool/adapter/scanner/
DREADME_zh.md47 "/application-entry-default.hap/libs/armeabi-v7a/example.so",
48 "/entry-default.hap/libs/armeabi-v7a/example.so"
91 <td>/application-entry-default.hap/libs/armeabi-v7a/example.so</td>
94 <td>/entry-default.hap/libs/armeabi-v7a/example.so</td>
144 "file":"/application-entry-default.hap/libs/x86_64/example.so",
180 <td>/application-entry-default.hap/libs/x86_64/example.so</td>
230 "test.app/application-entry-default.hap",
231 "test.app/entry-default.hap"
238 "file":"/application-entry-default.hap/libs/x86_64/example.so",
246 "file":"/application-entry-default.hap/ets/modules.abc",
[all …]
/developtools/hapsigner/hapsigntool_cpp_test/unittest/codeSigning/fsverity/
Dfs_verity_generator_test.cpp28 …d)rename("./codeSigning/entry-default-signed-so.txt", "./codeSigning/entry-default-signed-so.hap"); in SetUpTestCase()
48 std::ifstream inputStream("./codeSigning/entry-default-signed-so.hap", std::ios::binary);
66 std::ifstream inputStream("./codeSigning/entry-default-signed-so.hap", std::ios::binary);
84 std::ifstream inputStream("./codeSigning/entry-default-signed-so.hap", std::ios::binary);
103 std::ifstream inputStream("./codeSigning/entry-default-signed-so.hap", std::ios::binary);
122 std::ifstream inputStream("./codeSigning/entry-default-signed-so.hap", std::ios::binary);
141 std::ifstream inputStream("./codeSigning/entry-default-signed-so.hap", std::ios::binary);
160 std::ifstream inputStream("./codeSigning/entry-default-signed-so.hap", std::ios::binary);
179 std::ifstream inputStream("./codeSigning/entry-default-signed-so.hap", std::ios::binary);
/developtools/profiler/host/smartperf/client/client_ui/entry/src/main/resources/base/element/
Dstring.json29 "value": "hap sample empty service"
33 "value": "hap sample empty service"
53 "value": "hap sample empty service"
/developtools/hapsigner/hapsigntool_cpp_test/unittest/hapSign/
Dsign_provider_test.cpp34 outfile << "Hello, this is a Unvaild un provider Hap.\n"; in GenUnvaildUnProviderHap()
44 GenUnvaildUnProviderHap("./hapSign/nohap.hap"); in SetUpTestCase()
46 …"./hapSign/packages/phone-default-unsigned-test.txt", "./hapSign/phone-default-unsigned-test.hap"); in SetUpTestCase()
47 …id)rename("./hapSign/packages/phone-default-unsigned.txt", "./hapSign/phone-default-unsigned.hap"); in SetUpTestCase()
48 …ame("./hapSign/packages/unsigned_with_cd_and_eocd.txt", "./hapSign/unsigned_with_cd_and_eocd.hap"); in SetUpTestCase()
49 (void)rename("./hapSign/packages/unsigned_with_eocd.txt", "./hapSign/unsigned_with_eocd.hap"); in SetUpTestCase()
50 (void)rename("./codeSigning/unsigned-file.txt", "./codeSigning/unsigned-file.hap"); in SetUpTestCase()
77 std::string inFile = "./hapSign/phone-default-unsigned-test.hap";
79 std::string outFile = "./hapSign/phone-default-unsigned-test.hap";
118 std::string inFile = "./hapSign/phone-default-unsigned.hap";
[all …]
/developtools/hapsigner/autosign/
DsignHap.config5 config.signtool=../hapsigntool/hap_sign_tool/build/libs/hap-sign-tool.jar
31 sign.app.inFile=app1-unsigned.hap
32 sign.app.outFile=app1-signed.hap
/developtools/hapsigner/hapsigntool_cpp/utils/src/
Dhap_signer_block_utils.cpp55 * The package of hap is ZIP format, and contains four segments: contents of Zip entry,
56 * hap signatures block, central directory and end of central directory.
57 * The function will find the data segment of hap signature block from hap file.
85 * EoCD has an optional comment block. Most hap packages do not contain this block. in FindEocdInHap()
86 * For hap packages without comment block, EoCD is the last 22 bytes of hap file. in FindEocdInHap()
87 * Try as a hap without comment block first to avoid unnecessarily reading more data. in FindEocdInHap()
119 SIGNATURE_TOOLS_LOGE("read data from hap file error: %" PRId64, ret); in FindEocdInHap()
231 SIGNATURE_TOOLS_LOGE("HAP too small for HAP Signing Block: %" PRId64, centralDirOffset); in FindHapSigningBlock()
235 * read hap signing block head, it's format: in FindHapSigningBlock()
263 SIGNATURE_TOOLS_LOGE("HAP Signing Block offset out of range %" PRId64, hapSignBlockOffset); in FindHapSigningBlock()
[all …]

12345678910