~/talk

The Java Agent: Modifying Bytecode at Runtime to Protect Against Log4J

Talkat GOTO Copenhagen 2022 · 2022-10-03..10-07· [security, java]
slides:none on file

Shows how the Java Agent API is used to attach both dynamic attach and static agent to a running JVM, enumerate classes (JBOM), and perform runtime bytecode patching with ASM bytecode rewrite. Demonstrates loading an agent jar, intercepting javax.naming/Lookup, replacing the lookup method to return null, and stopping a Log4Shell payload (demoed by preventing the calculator spawn). Provides working demos and repos (jbom and a cornflakerizer-rasp RASP); both attach modes and the bytecode patch successfully block the exploit.

AI-written summary · about

  1. 0:00Intro
  2. 0:35java.langinstrumentation
  3. 2:21Dynamically attaching
  4. 8:14JBOM Demo
  5. 21:21Static attaching
  6. 21:46RASPs
  7. 22:29Log4J interpolation
  8. 23:58What is JNDI
  9. 24:54What a malicious JNDI server can do
  10. 29:10Patching Log4J at runtime
  11. 30:00Vulnerability Demo
  12. 38:12Links
  13. 38:43Outro
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.