From 57b8a73f750f009b03ce2bc60730de41b69a2028 Mon Sep 17 00:00:00 2001 From: JoyChou Date: Wed, 6 Sep 2017 18:55:39 +0800 Subject: [PATCH] change groupid --- .idea/workspace.xml | 66 +++++++++++++++++++++-------------------- README.md | 7 +++-- pom.xml | 2 +- src/main/java/test.java | 6 ++-- 4 files changed, 42 insertions(+), 39 deletions(-) diff --git a/.idea/workspace.xml b/.idea/workspace.xml index d2a0f31..91c3562 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -3,6 +3,8 @@ + + @@ -28,22 +30,22 @@ - + - - + + - + - - + + @@ -54,8 +56,8 @@ - - + + @@ -67,8 +69,8 @@ - - + + @@ -103,10 +105,10 @@ @@ -117,8 +119,8 @@ DEFINITION_ORDER - @@ -684,12 +686,12 @@ 1504604417100 - + - @@ -701,7 +703,7 @@ - + @@ -718,7 +720,7 @@ - + @@ -862,18 +864,10 @@ - - - - - - - - - - + + @@ -882,8 +876,8 @@ - - + + @@ -894,13 +888,21 @@ - - + + + + + + + + + + \ No newline at end of file diff --git a/README.md b/README.md index a7accb7..4cdcdc4 100644 --- a/README.md +++ b/README.md @@ -20,9 +20,9 @@ 合法URL返回true,非法URL返回false。 ```java -security checkUrl = new security(); +security urlCheck = new security(); String[] urlWList = {"joychou.com", "joychou.me"}; -Boolean ret = checkUrl.checkUrlWlist("http://test.joychou.me", urlWList); +Boolean ret = urlCheck.checkUrlWlist("http://test.joychou.me", urlWList); ``` ## checkSSRF @@ -42,8 +42,9 @@ Boolean ret = checkUrl.checkUrlWlist("http://test.joychou.me", urlWList); URL只支持HTTP协议。 ```java +security urlCheck = new security(); String url = "http://dns_rebind.joychou.me"; -ret = checkUrl.checkSSRF(url); +ret = urlCheck.checkSSRF(url); if (ret){ // curl url } diff --git a/pom.xml b/pom.xml index a8c10cc..37b2d20 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 - trident + com.joychou.trident trident 1.0.0 diff --git a/src/main/java/test.java b/src/main/java/test.java index cda3bc5..19cabc8 100644 --- a/src/main/java/test.java +++ b/src/main/java/test.java @@ -9,14 +9,14 @@ public class test { public static void main(String[] args) throws Exception { // URL白名单组件测试 - security checkUrl = new security(); + security urlCheck = new security(); String[] urlWList = {"joychou.com", "joychou.me"}; - Boolean ret = checkUrl.checkUrlWlist("http://test.joychou.org", urlWList); + Boolean ret = urlCheck.checkUrlWlist("http://test.joychou.org", urlWList); System.out.println(ret); // SSRF组件测试 String url = "http://dns_rebind.joychou.me"; - ret = checkUrl.checkSSRF(url); + ret = urlCheck.checkSSRF(url); if (ret){ String con = Request.Get(url).execute().returnContent().toString(); System.out.println(con);