Score:2

How to scan for log4j on Windows Server

vn flag

I have a Windows Server 2012 R2 machine. What is the best way to search for log4j. Is it enough with a simple file search or can these files be used from inside a container. I have done a file search like this in power shell

Get-childitem -Path c:\ -Include log4j*.jar -File -Recurse -ErrorAction SilentlyContinue | select Lastwritetime, directory, name | export-csv -append -notypeinformation c.csv
Score:2
cn flag

That is definitely insufficient. You need something to open up war/jar/etc files and inspect inside there. Further, depending on the filename to match isn't guaranteed to work. Finally, you're not checking on the version with that, so you'd also need to determine if you're running a vulnerable version.

This page has a link to a github project that does claim to do these things.

Score:0
br flag

Syft creates a software bill of materials, which you can in turn search for log4j occurrences.

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.