-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added default context menu entries: decoder++, droopescan, mooscan, w…
…pscan, bfac, gobuster, nikto, wfuzz, sqlmap, sslscan, sslyze, testssl Added additional placeholders: host, port, protocol, url, path, query, method, cookies, request/response, body Enhanced logging
- Loading branch information
1 parent
7332758
commit c948668
Showing
12 changed files
with
845 additions
and
272 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
apply plugin: 'java' | ||
|
||
group 'net.bytebutcher' | ||
version '0.95' | ||
version '0.98' | ||
|
||
sourceCompatibility = 1.8 | ||
|
||
|
166 changes: 93 additions & 73 deletions
166
burp-send-to-extension/src/main/java/burp/BurpExtender.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,73 +1,93 @@ | ||
package burp; | ||
|
||
import net.bytebutcher.burpsendtoextension.gui.SendToContextMenu; | ||
import net.bytebutcher.burpsendtoextension.gui.SendToTab; | ||
import net.bytebutcher.burpsendtoextension.gui.SendToTable; | ||
import net.bytebutcher.burpsendtoextension.models.Config; | ||
import net.bytebutcher.burpsendtoextension.utils.OsUtils; | ||
|
||
import javax.swing.*; | ||
import java.awt.*; | ||
import java.io.File; | ||
import java.io.PrintWriter; | ||
|
||
public class BurpExtender implements IBurpExtender, ITab { | ||
|
||
private JPanel tab = null; | ||
private SendToTab sendToTab = null; | ||
private IBurpExtenderCallbacks callbacks; | ||
private SendToContextMenu sendToContextMenu; | ||
private Config config; | ||
private SendToTable sendToTable; | ||
private PrintWriter stderr; | ||
|
||
@Override | ||
public void registerExtenderCallbacks(IBurpExtenderCallbacks callbacks) { | ||
this.callbacks = callbacks; | ||
this.callbacks.setExtensionName("Send to"); | ||
this.stderr = new PrintWriter(callbacks.getStderr(), true); | ||
this.config = new Config(this); | ||
this.sendToTab = new SendToTab(this); | ||
this.sendToContextMenu = new SendToContextMenu(this, this.sendToTab.getSendToTableListener()); | ||
this.callbacks.registerContextMenuFactory(sendToContextMenu); | ||
this.tab = sendToTab.getRootPanel(); | ||
this.sendToTable = this.sendToTab.getSendToTable(); | ||
this.sendToTable.addCommandObjects(this.config.getSendToTableData()); | ||
callbacks.addSuiteTab(this); | ||
} | ||
|
||
@Override | ||
public String getTabCaption() { | ||
return "Send to"; | ||
} | ||
|
||
@Override | ||
public Component getUiComponent() { | ||
return this.tab; | ||
} | ||
|
||
public ImageIcon createImageIcon(String path, String description, int width, int height) { | ||
java.net.URL imgURL = getClass().getResource(path); | ||
if (imgURL != null) { | ||
ImageIcon icon = new ImageIcon(imgURL); | ||
Image image = icon.getImage().getScaledInstance(width, height, Image.SCALE_SMOOTH); | ||
return new ImageIcon(image, description); | ||
} else { | ||
stderr.println("Couldn't find file: " + path); | ||
return null; | ||
} | ||
} | ||
|
||
public Config getConfig() { | ||
return this.config; | ||
} | ||
|
||
public JFrame getParent() { | ||
return this.sendToTab.getParent(); | ||
} | ||
|
||
public IBurpExtenderCallbacks getCallbacks() { | ||
return this.callbacks; | ||
} | ||
|
||
} | ||
package burp; | ||
|
||
import net.bytebutcher.burpsendtoextension.gui.SendToContextMenu; | ||
import net.bytebutcher.burpsendtoextension.gui.SendToTab; | ||
import net.bytebutcher.burpsendtoextension.gui.SendToTable; | ||
import net.bytebutcher.burpsendtoextension.models.Config; | ||
import net.bytebutcher.burpsendtoextension.utils.OsUtils; | ||
|
||
import javax.swing.*; | ||
import java.awt.*; | ||
import java.io.File; | ||
import java.io.PrintWriter; | ||
|
||
public class BurpExtender implements IBurpExtender, ITab { | ||
|
||
private JPanel tab = null; | ||
private SendToTab sendToTab = null; | ||
private IBurpExtenderCallbacks callbacks; | ||
private SendToContextMenu sendToContextMenu; | ||
private Config config; | ||
private SendToTable sendToTable; | ||
|
||
private static PrintWriter stdout; | ||
private static PrintWriter stderr; | ||
|
||
@Override | ||
public void registerExtenderCallbacks(IBurpExtenderCallbacks callbacks) { | ||
this.callbacks = callbacks; | ||
initLogHandler(callbacks); | ||
BurpExtender.printOut("Initializing Send to Extension..."); | ||
this.callbacks.setExtensionName("Send to"); | ||
BurpExtender.printOut("Initializing config..."); | ||
this.config = new Config(this); | ||
BurpExtender.printOut("Initializing tab..."); | ||
this.sendToTab = new SendToTab(this); | ||
BurpExtender.printOut("Registering context menu..."); | ||
this.sendToContextMenu = new SendToContextMenu(this, this.sendToTab.getSendToTableListener()); | ||
this.callbacks.registerContextMenuFactory(sendToContextMenu); | ||
this.tab = sendToTab.getRootPanel(); | ||
BurpExtender.printOut("Loading table data..."); | ||
this.sendToTable = this.sendToTab.getSendToTable(); | ||
this.sendToTable.addCommandObjects(this.config.getSendToTableData()); | ||
callbacks.addSuiteTab(this); | ||
BurpExtender.printOut("----------------------------------------------------------------------"); | ||
} | ||
|
||
private void initLogHandler(IBurpExtenderCallbacks callbacks) { | ||
this.stderr = new PrintWriter(callbacks.getStderr(), true); | ||
this.stdout = new PrintWriter(callbacks.getStdout(), true); | ||
} | ||
|
||
@Override | ||
public String getTabCaption() { | ||
return "Send to"; | ||
} | ||
|
||
@Override | ||
public Component getUiComponent() { | ||
return this.tab; | ||
} | ||
|
||
public ImageIcon createImageIcon(String path, String description, int width, int height) { | ||
java.net.URL imgURL = getClass().getResource(path); | ||
if (imgURL != null) { | ||
ImageIcon icon = new ImageIcon(imgURL); | ||
Image image = icon.getImage().getScaledInstance(width, height, Image.SCALE_SMOOTH); | ||
return new ImageIcon(image, description); | ||
} else { | ||
BurpExtender.printErr("Couldn't find file: " + path); | ||
return null; | ||
} | ||
} | ||
|
||
public Config getConfig() { | ||
return this.config; | ||
} | ||
|
||
public JFrame getParent() { | ||
return this.sendToTab.getParent(); | ||
} | ||
|
||
public IBurpExtenderCallbacks getCallbacks() { | ||
return this.callbacks; | ||
} | ||
|
||
public static void printOut(String s) { | ||
stdout.println(s); | ||
} | ||
|
||
public static void printErr(String s) { | ||
stderr.println(s); | ||
} | ||
} |
Oops, something went wrong.