Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Search for log4j inside jar files #2

Open
Dareeo opened this issue Dec 14, 2021 · 5 comments
Open

Search for log4j inside jar files #2

Dareeo opened this issue Dec 14, 2021 · 5 comments
Labels
wontfix This will not be worked on

Comments

@Dareeo
Copy link

Dareeo commented Dec 14, 2021

Hello,
Is it possible to extend the searching inside .jar files?
I mean change $log4Filter = "*.jar" and add extra logic to check all .jar files within found .jar files.
For example to find this file as well:

d:\someJAVAApp\iamajava.jar\BOOT-INF\lib\og4j-core-2.14.1.jar

Thanks

@sp4ir
Copy link
Owner

sp4ir commented Dec 14, 2021

Good call, I will look into it tonight. I don't have ready examples to test off of and may not be able to deliver this quickly.

@Dareeo
Copy link
Author

Dareeo commented Dec 15, 2021

Hello,
Great, thanks. Actually, You can easily reproduce it with zipping some files incluging affected log4j v2 and renameing the archive to zip. Also I can help with testing if needed.

@Tdue21
Copy link

Tdue21 commented Dec 16, 2021

This script will also search through mapped network drives, yes?

Not that it is a technical issue as such, other than it would potentially be a extraordinarily large amount of files, instead of just on local drives.

@sp4ir
Copy link
Owner

sp4ir commented Dec 22, 2021

This script will also search through mapped network drives, yes?

Not that it is a technical issue as such, other than it would potentially be a extraordinarily large amount of files, instead of just on local drives.

If run under a user context with mapped drives, yes. We have been deploying with endpoint tools that run under system context and would not have mapped drives.

@sp4ir sp4ir added the wontfix This will not be worked on label Dec 22, 2021
@sp4ir
Copy link
Owner

sp4ir commented Dec 22, 2021

Hello, Great, thanks. Actually, You can easily reproduce it with zipping some files incluging affected log4j v2 and renameing the archive to zip. Also I can help with testing if needed.

I am not going to pursue adding capability for nested archive files for now due to having to extract a archive file and then loop through it and the complexities involved. Recommend looking to this project for your use-case:
https://github.com/logpresso/CVE-2021-44228-Scanner

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
wontfix This will not be worked on
Projects
None yet
Development

No branches or pull requests

3 participants