Goal Reached Thanks to every supporter — we hit 100%!

Goal: 1000 CNY · Raised: 1000 CNY

100.0%

CVE-2022-1471 PoC — SnakeYAML 代码问题漏洞

Source
Associated Vulnerability
Title:SnakeYAML 代码问题漏洞 (CVE-2022-1471)
Description:SnakeYAML是一款基于Java的YAML解析器。 SnakeYaml存在代码问题漏洞,该漏洞源于不限制在反序列化期间可以实例化的类型。攻击者利用该漏洞可以远程执行代码。
Description
Code for veracode blog
Readme
# SnakeYAML-CVE-2022-1471-POC
Code for veracode blog

To demonstrate the Code Execution, 
1. Build the project using maven 
2. Execute `python3 -m http.server 8080` to run the http server
3. Run `exploit.java`. You should observe a HTTP GET request on the server
4. To demonstrate how SnakeYAML 2.0 prevents the attack, comment out the 1.33 dependency in the `pom.xml`
5. Uncomment the 2.0 dependency, then rebuild the project, 
6. Comment out `exploit.java` and uncomment `Poc.java`
7. Run `Poc.java` and observe no GET request
File Snapshot

[4.0K] /data/pocs/e562d5919f84ec5ca40c5e67d6aa222bdd0a9773 ├── [1.1K] pom.xml ├── [ 529] README.md └── [4.0K] src └── [4.0K] main └── [4.0K] java └── [4.0K] org └── [4.0K] example ├── [ 756] exploit.java └── [1.2K] Poc.java 5 directories, 4 files
Shenlong Bot has cached this for you
Remarks
    1. It is advised to access via the original source first.
    2. If the original source is unavailable, please email f.jinxu#gmail.com for a local snapshot (replace # with @).
    3. Shenlong has snapshotted the POC code for you. To support long-term maintenance, please consider donating. Thank you for your support.