/developtools/hapsigner/hapsigntool_cpp/codesigning/sign/src/ |
H A D | verify_code_signature.cpp | 34 CodeSignBlock csb; in VerifyHap() local 35 bool generateFlag = GenerateCodeSignBlock(file, offset, length, csb); in VerifyHap() 41 bool verifyFlag = VerifyCodeSign(file, pairResult, csb); in VerifyHap() 101 bool VerifyCodeSignature::VerifyNativeLib(CodeSignBlock& csb, std::string& file, unzFile& zFile, in VerifyNativeLib() argument 104 UnzipHandleParam param(csb, pairResult, false); in VerifyNativeLib() 115 CodeSignBlock& csb) in VerifyCodeSign() 123 int64_t dataSize = csb.GetHapInfoSegment().GetSignInfo().GetDataSize(); in VerifyCodeSign() 124 std::vector<int8_t> signature = csb.GetHapInfoSegment().GetSignInfo().GetSignature(); in VerifyCodeSign() 125 Extension* ext = csb.GetHapInfoSegment().GetSignInfo() in VerifyCodeSign() 140 csb in VerifyCodeSign() 114 VerifyCodeSign(std::string file, std::pair<std::string, std::string>& pairResult, CodeSignBlock& csb) VerifyCodeSign() argument 181 GenerateCodeSignBlock(const std::string& file, int64_t offset, int64_t length, CodeSignBlock& csb) GenerateCodeSignBlock() argument 234 ParseSegmentHead(CodeSignBlock& csb, std::ifstream& signedHap, std::vector<char> &merkleTreeBytes, int32_t &fileReadOffset) ParseSegmentHead() argument 272 ParseMerkleTree(CodeSignBlock& csb, int32_t readOffset, std::ifstream& signedHap, int64_t computedTreeOffset) ParseMerkleTree() argument [all...] |
H A D | code_signing.cpp | 389 CodeSignBlock csb = param.GetCodeSignBlock(); in DoNativeLibVerify() local 390 std::vector<std::string>& fileNames = csb.GetSoInfoSegment().GetFileNameList(); in DoNativeLibVerify() 397 for (int j = 0; j < csb.GetSoInfoSegment().GetSectionNum(); j++) { in DoNativeLibVerify() 398 SignInfo signInfo = csb.GetSoInfoSegment().GetSignInfoList()[j]; in DoNativeLibVerify() 399 std::string entryName = csb.GetSoInfoSegment().GetFileNameList()[j]; in DoNativeLibVerify()
|
/developtools/hapsigner/hapsigntool/hap_sign_tool_lib/src/main/java/com/ohos/hapsigntool/codesigning/sign/ |
H A D | VerifyCodeSignature.java | 189 CodeSignBlock csb = generateCodeSignBlock(file, offset, length); in verifyHap() 192 long dataSize = csb.getHapInfoSegment().getSignInfo().getDataSize(); in verifyHap() 193 byte[] signature = csb.getHapInfoSegment().getSignInfo().getSignature(); in verifyHap() 194 Extension extension = csb.getHapInfoSegment() in verifyHap() 203 csb.getOneMerkleTreeByFileName(CodeSigning.HAP_SIGNATURE_ENTRY_NAME)); in verifyHap() 207 verifyLibs(file, csb, pairResult); in verifyHap() 211 private static void verifyLibs(File file, CodeSignBlock csb, Pair<String, String> pairResult) in verifyLibs() argument 216 for (int i = 0; i < csb.getSoInfoSegment().getSectionNum(); i++) { in verifyLibs() 217 String entryName = csb.getSoInfoSegment().getFileNameList().get(i); in verifyLibs() 218 SignInfo signInfo = csb in verifyLibs() 315 parseMerkleTree(CodeSignBlock csb, int readOffset, FileInputStream signedHap, long computedTreeOffset) parseMerkleTree() argument [all...] |
/developtools/hapsigner/hapsigntool_cpp/codesigning/datastructure/src/ |
H A D | unzip_handle_param.cpp | 21 UnzipHandleParam::UnzipHandleParam(const CodeSignBlock& csb, const std::pair<std::string, std::string>& pairResult, in UnzipHandleParam() argument 24 this->csb = csb; in UnzipHandleParam() 39 return csb; in GetCodeSignBlock()
|
/developtools/hapsigner/hapsigntool_cpp/codesigning/sign/include/ |
H A D | verify_code_signature.h | 40 static bool VerifyNativeLib(CodeSignBlock& csb, std::string& file, unzFile& zFile, 43 std::string>& pairResult, CodeSignBlock& csb); 50 CodeSignBlock& csb); 51 static bool ParseSegmentHead(CodeSignBlock& csb, std::ifstream& signedHap, 53 static bool ParseMerkleTree(CodeSignBlock& csb, int32_t readOffset, std::ifstream& signedHap,
|
/developtools/hapsigner/hapsigntool_cpp/codesigning/datastructure/include/ |
H A D | unzip_handle_param.h | 27 UnzipHandleParam(const CodeSignBlock& csb, const std::pair<std::string, std::string>& pairResult, bool isSign); 36 CodeSignBlock csb; member in OHOS::SignatureTools::UnzipHandleParam
|
/developtools/hapsigner/hapsigntool_cpp_test/unittest/codeSigning/sign/ |
H A D | verify_code_signature_test.cpp | 115 CodeSignBlock csb; in HWTEST_F() local 116 bool flag = VerifyCodeSignature::VerifyCodeSign(file, pairResult, csb); in HWTEST_F() 457 CodeSignBlock csb; in HWTEST_F() local 458 bool flag = VerifyCodeSignature::VerifyNativeLib(csb, file, zFile, pairResult); in HWTEST_F()
|