Skip to content
KitploitKITPLOIT
أدواتالمدونة
إرسال
أدواتالمدونة
إرسال

أدوات الاختراق واختبار الاختراق والأمن السيبراني لترسانتك الأمنية!

Kitploit هو دليل لأدوات الاختراق والأمن السيبراني واختبار الاختراق. اكتشف آخر تحديثات المشاريع للعثور على الثغرات وتحليل الأنظمة وأتمتة الاختبارات وتعزيز أمنك.

··الخلاصات·اتصال·الخصوصية·© 2026 Kitploit

دليل الأدوات

الفئات

عرض جميع الفئات
Loading categories
أدوات/GitHubGitHub/logpresso/cve-2021-44228-scanner
ماسحات الثغرات الأمنيةتحليل الثغرات الأمنيةتدقيق التكوينأمن سلسلة التوريدالاستجابة للحوادثتحليل السجلات
GitHublogpresso/cve-2021-44228-scanner

CVE-2021-44228-Scanner

ماسح الثغرات وتصحيح التخفيف لـ Log4j2 CVE-2021-44228

عرض المستودع
8611695منذ 4 سنواتتمت المراجعة من قبل Kitploit

الأكثر شعبية

عرض الكل →

اكتشف الأدوات الأكثر استخدامًا من قبل مجتمعنا.

استكشف جميع الأدوات

تصفح مجموعتنا من الأدوات

عرض جميع الأدوات →
مشاركة

شعار Logpresso

log4j2-scan هي أداة سطر أوامر في ملف ثنائي واحد لفحص ثغرة CVE-2021-44228 وتطبيق التصحيح التخفيفي. كما تدعم فحص ملفات JAR المتداخلة وتصحيحها. كما تكتشف الثغرات CVE-2021-45046 (log4j 2.15.0) وCVE-2021-45105 (log4j 2.16.0) وCVE-2021-44832 (log4j 2.17.0) وCVE-2021-4104 وCVE-2019-17571 وCVE-2017-5645 وCVE-2020-9488 وCVE-2022-23302 وCVE-2022-23305 وCVE-2022-23307 (log4j 1.x) وCVE-2021-42550 (logback 0.9-1.2.7).

إدارة مخاطر Log4j

يمكنك دمج log4j2-scan مع خدمة Logpresso Watch لإعداد التقارير وإدارة التصحيحات. تفضل بزيارة https://logpresso.watch للحصول على التفاصيل.

التنزيل

  • log4j2-scan 3.0.1 (Windows x64, 7z)
  • log4j2-scan 3.0.1 (Windows x64, zip)
    • إذا ظهر خطأ VCRUNTIME140.dll not found، فقم بتثبيت Visual C++ Redistributable.
    • إذا لم يعمل الملف التنفيذي الأصلي، فاستخدم JAR بدلاً منه. إصدار 32 بت غير مدعوم.
    • يتوفر 7zip من www.7zip.org، وهو مفتوح المصدر ومجاني.
  • log4j2-scan 3.0.1 (Linux x64)
  • log4j2-scan 3.0.1 (Linux aarch64)
    • إذا لم يعمل الملف التنفيذي الأصلي، فاستخدم JAR بدلاً منه. إصدار 32 بت غير مدعوم.
  • log4j2-scan 3.0.1 (Mac OS)
  • log4j2-scan 3.0.1 (أي نظام تشغيل، 620KB)
  • البناء

    • كيفية بناء Native Image

    طريقة الاستخدام

    ما عليك سوى تشغيل log4j2-scan.exe أو log4j2-scan مع مسار الدليل الهدف. يجب أن يعمل ملف logpresso-log4j2-scan.jar مع JRE/JDK 7+

    خيار --fix مدعوم للثغرات التالية:

    • Log4j v2
      • CVE-2021-44228 (JndiLookup)
      • CVE-2021-45046 (JndiLookup)
    • Log4j v1
      • CVE-2021-4104 (JMSAppender)
      • CVE-2019-17571 (SocketServer)
      • CVE-2020-9488 (SMTPAppender)
      • CVE-2022-23302 (JMSSink)
      • CVE-2022-23305 (JDBCAppender)
      • CVE-2022-23307 (حزمة chainsaw)

    خيار --fix لا يخفف الثغرات التالية:

    • Log4j v2
      • CVE-2021-44832 (JDBCAppender)
      • CVE-2021-45105 (DoS)
      • CVE-2017-5645 (SocketServer)
      • CVE-2020-9488 (SMTPAppender)
    • Logback
      • CVE-2021-42550

    الاستخدام

    root@kitploit:~
    Logpresso CVE-2021-44228 Vulnerability Scanner 3.0.1 (2022-02-13)
    Usage: log4j2-scan [--scan-log4j1] [--fix] target_path1 target_path2
    
    -f [config_file_path]
            Specify config file path which contains scan target paths.
            Paths should be separated by new line. Prepend # for comment.
    --scan-log4j1
            Enables scanning for log4j 1 versions.
    --scan-logback
            Enables scanning for logback CVE-2021-42550.
    --scan-zip
            Scan also .zip extension files. This option may slow down scanning.
    --zip-charset
            Specify an alternate zip encoding other than utf-8. System default charset is used if not specified.
    --fix
            Backup original file and remove JndiLookup.class from JAR recursively.
            With --scan-log4j1 option, it also removes JMSAppender.class, SocketServer.class, SMTPAppender.class, SMTPAppender$1.class,
            JMSSink.class, JDBCAppender.class, and all classes of org.apache.log4j.chainsaw package
    --force-fix
            Do not prompt confirmation. Don't use this option unless you know what you are doing.
    --restore [backup_file_path]
            Unfix JAR files using zip archived file.
    --backup-path [zip_output_path]
            Specify backup file path.
    --backup-ext [zip]
            Specify backup file extension. zip by default.
            If --backup-path is specified, this option is ignored.
    --all-drives
            Scan all drives on Windows
    --drives c,d
            Scan specified drives on Windows. Spaces are not allowed here.
    --no-symlink
            Do not detect symlink as vulnerable file.
    --exclude [path_prefix]
            Path prefixes of directories whose absolute path starts with the specified value will be excluded.
            Does not support relative paths. You can specify multiple --exclude [path_prefix] pairs
    --exclude-config [config_file_path]
            Specify exclude path prefix list in text file. Paths should be separated by new line. Prepend # for comment.
    --exclude-pattern [pattern]
            Exclude specified paths of directories by pattern. Supports fragments.
            You can specify multiple --exclude-pattern [pattern] pairs (non regex)
    --exclude-file-config [config_file_path]
            Specify exclude file path list in text file. Paths should be separated by new line. Prepend # for comment.
    --exclude-fs nfs,tmpfs
            Exclude paths by file system type. nfs, nfs3, nfs4, afs, cifs, autofs,
            tmpfs, devtmpfs, fuse.sshfs, smbfs and iso9660 is ignored by default.
    --api-key [key]
            Send reports to Logpresso Watch service.
    --http-proxy [addr:port]
            Send reports via specified HTTP proxy server.
    --syslog-udp [host:port]
            Send reports to remote syslog host.
            Send vulnerable, potentially vulnerable, and mitigated reports by default.
    --syslog-level [level]
            Send reports only if report is higher or equal to specified level.
            Specify alert for vulnerable and potentially vulnerable reports.
            Specify info for vulnerable, potentially vulnerable, and mitigated reports.
            Specify debug for vulnerable, potentially vulnerable, mitigated, and error reports.
    --syslog-facility [code]
            Default value is 16 (LOCAL0). Facility value must be in the range of 0 to 23 inclusive.
    --rfc5424
            Follow RFC5424 The Syslog Protocol strictly.
    --report-csv
            Generate log4j2_scan_report_yyyyMMdd_HHmmss.csv in working directory if not specified otherwise via --report-path [path]
    --report-json
            Generate log4j2_scan_report_yyyyMMdd_HHmmss.json in working directory if not specified otherwise via --report-path [path]
    --report-patch
            Report also patched log4j file.
    --report-path
            Specify report output path including filename. Implies --report-csv.
    --report-dir
            Specify report output directory. Implies --report-csv.
    --no-empty-report
            Do not generate empty report.
    --csv-log-path
            Specify csv log file path. If log file exists, log will be appended.
    --json-log-path
            Specify json log file path. If log file exists, log will be appended.
    --old-exit-code
            Return sum of vulnerable and potentially vulnerable files as exit code.
    --debug
            Print exception stacktrace for debugging.
    --trace
            Print all directories and files while scanning.
    --silent
            Do not print progress message.
    --throttle
            Limit scan files per second.
    --help
            Print this help.
    

    في Windows

    root@kitploit:~
    log4j2-scan [--fix] target_path
    

    في Linux

    root@kitploit:~
    ./log4j2-scan [--fix] target_path
    

    في UNIX (AIX وSolaris وما إلى ذلك)

    root@kitploit:~
    java -jar logpresso-log4j2-scan-3.0.1.jar [--fix] target_path
    

    إذا أضفت خيار --fix، فسوف ينسخ هذا البرنامج ملف JAR الأصلي المعرض للثغرة إلى ملف .bak، وينشئ ملف JAR جديدًا بدون إدخال org/apache/logging/log4j/core/lookup/JndiLookup.class. يتم أرشفة جميع ملفات .bak في ملف zip واحد باسم log4j2_scan_backup_yyyyMMdd_HHmmss.zip، ثم حذفها بأمان. في معظم البيئات، لن يتم استخدام ميزة بحث JNDI. ومع ذلك، يجب عليك استخدام هذا الخيار على مسؤوليتك الخاصة. يمكنك بسهولة استعادة ملفات JAR الأصلية المعرضة للثغرة باستخدام خيار --restore.

    اعتمادًا على نظام التشغيل:

    • Windows: من الضروري إيقاف تشغيل أي عملية JVM قيد التشغيل قبل تطبيق التصحيح بسبب ملفات القفل. ابدأ عملية JVM المتأثرة بعد الإصلاح.
    • Linux/macOS: طبّق التصحيح، وأعد تشغيل JVM بعد ذلك

    إذا كنت تريد أتمتة مهمة التصحيح، فاستخدم خيار --force-fix. مع هذا الخيار، لن يطلب هذا البرنامج التأكيد بعد الآن.

    سيتم عرض علامة (mitigated) إذا تمت إزالة إدخال org/apache/logging/log4j/core/lookup/JndiLookup.class من ملف JAR.

    إذا أضفت خيار --trace، فسوف يطبع هذا البرنامج جميع الدلائل والملفات التي تمت زيارتها. استخدم هذا الخيار لأغراض التصحيح فقط.

    في Windows:

    root@kitploit:~
    CMD> log4j2-scan.exe D:\tmp
    [*] Found CVE-2021-44228 vulnerability in D:\tmp\elasticsearch-7.16.0\bin\elasticsearch-sql-cli-7.16.0.jar, log4j 2.11.1
    [*] Found CVE-2021-44228 vulnerability in D:\tmp\elasticsearch-7.16.0\lib\log4j-core-2.11.1.jar, log4j 2.11.1
    [*] Found CVE-2021-44228 vulnerability in D:\tmp\flink-1.14.0\lib\log4j-core-2.14.1.jar, log4j 2.14.1
    [*] Found CVE-2021-44228 vulnerability in D:\tmp\logstash-7.16.0\logstash-core\lib\jars\log4j-core-2.14.0.jar, log4j 2.14.0
    [*] Found CVE-2021-44228 vulnerability in D:\tmp\logstash-7.16.0\vendor\bundle\jruby\2.5.0\gems\logstash-input-tcp-6.2.1-java\vendor\jar-dependencies\org\logstash\inputs\logstash-input-tcp\6.2.1\logstash-input-tcp-6.2.1.jar, log4j 2.9.1
    [*] Found CVE-2021-44228 vulnerability in D:\tmp\solr-7.7.3\solr-7.7.3\contrib\prometheus-exporter\lib\log4j-core-2.11.0.jar, log4j 2.11.0
    [*] Found CVE-2021-44228 vulnerability in D:\tmp\solr-7.7.3\solr-7.7.3\server\lib\ext\log4j-core-2.11.0.jar, log4j 2.11.0
    [*] Found CVE-2021-44228 vulnerability in D:\tmp\solr-8.11.0\contrib\prometheus-exporter\lib\log4j-core-2.14.1.jar, log4j 2.14.1
    [*] Found CVE-2021-44228 vulnerability in D:\tmp\solr-8.11.0\server\lib\ext\log4j-core-2.14.1.jar, log4j 2.14.1
    
    Scanned 5047 directories and 26251 files
    Found 9 vulnerable files
    Completed in 0.42 seconds
    

    كيف يعمل

    يعمل في 5 خطوات:

    1. ابحث بشكل متكرر عن جميع ملفات .jar و.war و.ear و.aar و.rar و.nar.
    2. ابحث عن إدخال META-INF/maven/org.apache.logging.log4j/log4j-core/pom.properties في ملف JAR.
    3. اقرأ groupId وartifactId والإصدار.
    4. قارن إصدار log4j2 واطبع الإصدار المعرض للثغرة.
    5. إذا تم استخدام خيار --fix، فقم بنسخ الملف المعرض للثغرة احتياطيًا وتصحيحه.
      • على سبيل المثال، يتم نسخ الملف الأصلي vulnerable.jar إلى vulnerable.jar.bak
    6. أرشفة جميع ملفات النسخ الاحتياطي في ملف zip باسم log4j2_scan_backup_yyyyMMdd_HHmmss.zip، ثم حذف ملفات .bak.

    رمز الخروج للأتمتة

    • -1 فشل التشغيل
    • 0 للحالة النظيفة (لا توجد ثغرات)
    • 1 لوجود ثغرات
    • 2 لوجود بعض الأخطاء

    تكاملات الأدوات

    • HCL BigFix
    • Checkmk
      • انظر أيضًا مكوّن checkmk الإضافي لعامل CVE-log4j

    التواصل

    إذا كان لديك أي سؤال أو مشكلة، فأنشئ issue في هذا المستودع.

    حول Logpresso

    Logpresso هي شركة رائدة في صناعة الذكاء الاصطناعي والبيانات الضخمة، وتقع في كوريا الجنوبية. توفر Logpresso حلول SIEM وSOAR وإدارة السجلات وFDS مع منصة البيانات الضخمة الخاصة بها.

    تنزيل الأداة