Log4Shell Log4j vulnerability (CVE-2021-44228) – cheat-sheet reference guide
151–160 of 209 posts
Re: Log4Shell Log4j vulnerability (CVE-2021-44228) – cheat-sheet reference guide
#152Re: Log4Shell Log4j vulnerability (CVE-2021-44228) – cheat-sheet reference guide
#153Earlier quoted context omitted.
> Ideally, log4j should not have the ability to make "outgoing calls" right? What is the intended scope of log4j? I spent some time looking over the source code and cannot fathom why something that logs information would need to become this complicated.
> I spent some time looking over the source code and cannot fathom why something that logs information would need to become this complicated. That's easy: because software development is complicated. If you look at the ticket where this was added[1], it seems like a reasonable request for something a very featureful logging library might do. Other logging frameworks[2] already supported this feature. It's easy to arm…
Re: Log4Shell Log4j vulnerability (CVE-2021-44228) – cheat-sheet reference guide
#154Re: Log4Shell Log4j vulnerability (CVE-2021-44228) – cheat-sheet reference guide
#155Not a Java programmer, I still don't really understand how the ability to inject a JNDI lookup to your sever results in an RCE. OK, an attacker can inject a JNDI lookup, and can control what the JNDI lookup via LDAP returns... I would have thought that whatever it returned would just get inserted as a string into the log output, no big deal. But a remote JNDI lookup can return code that gets executed on the local sit…
Once you can inject anything that gets resolved, you have an information disclosure vulnerability unrelated to the RCE.
If I can just DNS resolve any ${env} variable from the JVM, a lot of systems are compromised by just exposing the env or system variables configured for runtime.
Just getting your $AWS_ACCESS_KEY_ID and $AWS_SECRET_ACCESS_KEY env vars can compromise your bucket (sure, that is a really unsafe setup now, but it was almost the standard a few years ago over configuring it explicitly).
So a logging system which will merely resolve a hostname derived from a variable was bad enough to compromise many systems.
The serialization loophole was fixed in a jdk8 update.
https://github.com/openjdk/jdk8u/commit/006e84fc77a582552e71...
But even with that in place, the information disclosure of java System or env properties is bad enough to break actual systems in prod.
This is actually next level exposure, but I saw people trying to identify Tor node IPs using this method and geolocate them.
Re: Log4Shell Log4j vulnerability (CVE-2021-44228) – cheat-sheet reference guide
#156Re: Log4Shell Log4j vulnerability (CVE-2021-44228) – cheat-sheet reference guide
#157Earlier quoted context omitted.
but? It think it's far deeper than mitigation, it's the solution. Edit: I apologize for getting 'sanitation' wrong. Don't do it.
The proper solution to SQL injection is parameterized queries, not input sanitization, to my knowledge.
Re: Log4Shell Log4j vulnerability (CVE-2021-44228) – cheat-sheet reference guide
#158This might be a stupid question, but is it possible to airgap all classes running in the JVM from the network except for those you trust? For example, I want to block all classes from opening sockets except those in my.company.domain.* packages.
Re: Log4Shell Log4j vulnerability (CVE-2021-44228) – cheat-sheet reference guide
#159I have taken some flak over the years for rolling my own basics like logging, telemetry, tracing, authentication, session management, etc... Incidents like this remind me that it is sometimes OK to ignore those who constantly order you to "vendor it out" over some notion of principled development excellence wherein one never reinvents a single hypothetical wheel. Arguably, writing text to a log file on disk is a simp…
Re: Log4Shell Log4j vulnerability (CVE-2021-44228) – cheat-sheet reference guide
#160I have taken some flak over the years for rolling my own basics like logging, telemetry, tracing, authentication, session management, etc... Incidents like this remind me that it is sometimes OK to ignore those who constantly order you to "vendor it out" over some notion of principled development excellence wherein one never reinvents a single hypothetical wheel. Arguably, writing text to a log file on disk is a simp…
On the other hand, you don't know what vulnerabilities are hidden in your own code and just haven't been discovered yet, and you're one fuzzing attack away from a vulnerability being discovered/exploited.