Rebuild code and add default filter.

This commit is contained in:
AnonymousUser
2020-11-27 03:48:28 +08:00
parent 7b5027a528
commit 2ce57f8ee1
12 changed files with 464 additions and 272 deletions

34
burp/action/DoAction.java Normal file
View File

@@ -0,0 +1,34 @@
package burp.action;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import org.json.JSONObject;
import burp.Config;
public class DoAction {
public String extractString(JSONObject jsonObj) {
String result = "";
Iterator<String> k = jsonObj.keys();
while (k.hasNext()) {
String name = k.next();
JSONObject jsonObj1 = new JSONObject(jsonObj.get(name).toString());
String tmpStr = String.format(Config.outputTplString, name, jsonObj1.getString("data")).intern();
result += tmpStr;
}
return result;
}
public List<String> highlightList(JSONObject jsonObj) {
List<String> colorList = new ArrayList<String>();
Iterator<String> k = jsonObj.keys();
while (k.hasNext()) {
String name = k.next();
JSONObject jsonObj2 = new JSONObject(jsonObj.get(name).toString());
colorList.add(jsonObj2.getString("color"));
}
return colorList;
}
}