diff --git a/zh/security-vulntest/testcases/2023/05/OpenHarmony-SA-2023-0530/TestCaseInfo-OpenHarmony-SA-2023-0530.json b/zh/security-vulntest/testcases/2023/05/OpenHarmony-SA-2023-0530/TestCaseInfo-OpenHarmony-SA-2023-0530.json new file mode 100644 index 0000000000000000000000000000000000000000..dbeb29a9af7107c70f751af1e7a4c6825987445e --- /dev/null +++ b/zh/security-vulntest/testcases/2023/05/OpenHarmony-SA-2023-0530/TestCaseInfo-OpenHarmony-SA-2023-0530.json @@ -0,0 +1,15 @@ +{ + "description": "Configuration for yara demo Tests", + "driver": { + "type": "OHYaraTest", + "yara-bin": "yara64.exe", + "version-mapping-file": "openHarmony_version_mapping.json", + "vul-info-file": "vul_info_2023_05.json", + "tools-hap-info": { + "hap-file": "sststool.hap", + "bundle-name": "com.example.sststool" + } + }, + "kits": [ + ] +} \ No newline at end of file diff --git a/zh/security-vulntest/testcases/2023/05/OpenHarmony-SA-2023-0530/TestCaseRule-OpenHarmony-SA-2023-0530.yara b/zh/security-vulntest/testcases/2023/05/OpenHarmony-SA-2023-0530/TestCaseRule-OpenHarmony-SA-2023-0530.yara new file mode 100644 index 0000000000000000000000000000000000000000..9bb9eb5f4a2bcc94a5132d7cb51a80d633e493b0 --- /dev/null +++ b/zh/security-vulntest/testcases/2023/05/OpenHarmony-SA-2023-0530/TestCaseRule-OpenHarmony-SA-2023-0530.yara @@ -0,0 +1,16 @@ +import "console" + +rule TestCaseRule_OpenHarmony_SA_2023_0701 +{ + meta: + date = "2023-07-01" + file = "/system/lib/libcrypto.so" + + strings: + $vul = {8B ?? 14 85 DB} + $fix = {8B ?? 14 81 FB 4A 02 00 00 0F 8F ?? ?? 00 00 45 31 F6} + + condition: + ((not $vul) or $fix) and console.log("OpenHarmony-SA-2023-0701 testcase pass") +} +