-
Notifications
You must be signed in to change notification settings - Fork 54
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
67 changed files
with
5,468 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,93 @@ | ||
# Created by https://www.gitignore.io | ||
|
||
### OSX ### | ||
.DS_Store | ||
.AppleDouble | ||
.LSOverride | ||
|
||
# Icon must end with two \r | ||
Icon | ||
|
||
|
||
# Thumbnails | ||
._* | ||
|
||
# Files that might appear in the root of a volume | ||
.DocumentRevisions-V100 | ||
.fseventsd | ||
.Spotlight-V100 | ||
.TemporaryItems | ||
.Trashes | ||
.VolumeIcon.icns | ||
|
||
# Directories potentially created on remote AFP share | ||
.AppleDB | ||
.AppleDesktop | ||
Network Trash Folder | ||
Temporary Items | ||
.apdisk | ||
|
||
|
||
### Intellij ### | ||
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm | ||
|
||
*.iml | ||
|
||
## Directory-based project format: | ||
.idea/ | ||
# if you remove the above rule, at least ignore the following: | ||
|
||
# User-specific stuff: | ||
# .idea/workspace.xml | ||
# .idea/tasks.xml | ||
# .idea/dictionaries | ||
|
||
# Sensitive or high-churn files: | ||
# .idea/dataSources.ids | ||
# .idea/dataSources.xml | ||
# .idea/sqlDataSources.xml | ||
# .idea/dynamic.xml | ||
# .idea/uiDesigner.xml | ||
|
||
# Gradle: | ||
# .idea/gradle.xml | ||
# .idea/libraries | ||
|
||
# Mongo Explorer plugin: | ||
# .idea/mongoSettings.xml | ||
|
||
## File-based project format: | ||
*.ipr | ||
*.iws | ||
|
||
## Plugin-specific files: | ||
|
||
# IntelliJ | ||
/out/ | ||
/target/ | ||
|
||
# mpeltonen/sbt-idea plugin | ||
.idea_modules/ | ||
|
||
# JIRA plugin | ||
atlassian-ide-plugin.xml | ||
|
||
# Crashlytics plugin (for Android Studio and IntelliJ) | ||
com_crashlytics_export_strings.xml | ||
crashlytics.properties | ||
crashlytics-build.properties | ||
|
||
|
||
### Java ### | ||
*.class | ||
|
||
# Mobile Tools for Java (J2ME) | ||
.mtj.tmp/ | ||
|
||
# Package Files # | ||
*.jar | ||
*.war | ||
*.ear | ||
|
||
# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml | ||
hs_err_pid* |
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 |
---|---|---|
@@ -0,0 +1,23 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<project xmlns="http://maven.apache.org/POM/4.0.0" | ||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | ||
<modelVersion>4.0.0</modelVersion> | ||
|
||
<groupId>com.netspi.javaserialkiller</groupId> | ||
<artifactId>javaserialkiller</artifactId> | ||
<version>1.0-SNAPSHOT</version> | ||
|
||
<dependencies> | ||
<dependency> | ||
<groupId>org.reflections</groupId> | ||
<artifactId>reflections</artifactId> | ||
<version>0.9.10</version> | ||
</dependency> | ||
<dependency> | ||
<groupId>org.beanshell</groupId> | ||
<artifactId>bsh</artifactId> | ||
<version>2.0b5</version> | ||
</dependency> | ||
</dependencies> | ||
</project> |
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 |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package burp; | ||
|
||
public class BurpExtender implements IBurpExtender | ||
{ | ||
|
||
@Override | ||
public void registerExtenderCallbacks(IBurpExtenderCallbacks callbacks) | ||
{ | ||
|
||
callbacks.setExtensionName("Java Serial Killer"); | ||
|
||
callbacks.registerContextMenuFactory(new Menu(callbacks)); | ||
|
||
} | ||
} |
121 changes: 121 additions & 0 deletions
121
JavaSerialKiller/src/main/java/burp/ButtonTabComponent.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 |
---|---|---|
@@ -0,0 +1,121 @@ | ||
package burp; | ||
|
||
import java.awt.*; | ||
import java.awt.event.ActionEvent; | ||
import java.awt.event.ActionListener; | ||
import java.awt.event.MouseAdapter; | ||
import java.awt.event.MouseEvent; | ||
import java.awt.event.MouseListener; | ||
|
||
import javax.swing.*; | ||
import javax.swing.plaf.basic.BasicButtonUI; | ||
|
||
/** | ||
* Component to be used as tabComponent; Contains a JLabel to show the text and a JButton to close the tab it belongs to | ||
*/ | ||
public class ButtonTabComponent extends JPanel { | ||
|
||
private final JTabbedPane pane; | ||
|
||
public ButtonTabComponent(final JTabbedPane pane) { | ||
//unset default FlowLayout' gaps | ||
super(new FlowLayout(FlowLayout.LEFT, 0, 0)); | ||
if (pane == null) { | ||
throw new NullPointerException("TabbedPane is null"); | ||
} | ||
this.pane = pane; | ||
setOpaque(false); | ||
|
||
//make JLabel read titles from JTabbedPane | ||
JLabel label = new JLabel() { | ||
public String getText() { | ||
int i = pane.indexOfTabComponent(ButtonTabComponent.this); | ||
if (i != -1) { | ||
return pane.getTitleAt(i); | ||
} | ||
return null; | ||
} | ||
}; | ||
|
||
add(label); | ||
//add more space between the label and the button | ||
label.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 5)); | ||
//tab button | ||
JButton button = new TabButton(); | ||
add(button); | ||
//add more space to the top of the component | ||
setBorder(BorderFactory.createEmptyBorder(2, 0, 0, 0)); | ||
} | ||
|
||
private class TabButton extends JButton implements ActionListener { | ||
|
||
public TabButton() { | ||
int size = 17; | ||
setPreferredSize(new Dimension(size, size)); | ||
setToolTipText("close this tab"); | ||
//Make the button looks the same for all Laf's | ||
setUI(new BasicButtonUI()); | ||
//Make it transparent | ||
setContentAreaFilled(false); | ||
//No need to be focusable | ||
setFocusable(false); | ||
setBorder(BorderFactory.createEtchedBorder()); | ||
setBorderPainted(false); | ||
//Making nice rollover effect | ||
//we use the same listener for all buttons | ||
addMouseListener(buttonMouseListener); | ||
setRolloverEnabled(true); | ||
//Close the proper tab by clicking the button | ||
addActionListener(this); | ||
} | ||
|
||
public void actionPerformed(ActionEvent e) { | ||
int i = pane.indexOfTabComponent(ButtonTabComponent.this); | ||
if (i != -1) { | ||
pane.remove(i); | ||
JavaSerialKillerTab.removedTabCount++; | ||
} | ||
} | ||
|
||
//we don't want to update UI for this button | ||
public void updateUI() { | ||
} | ||
|
||
//paint the cross | ||
protected void paintComponent(Graphics g) { | ||
super.paintComponent(g); | ||
Graphics2D g2 = (Graphics2D) g.create(); | ||
//shift the image for pressed buttons | ||
if (getModel().isPressed()) { | ||
g2.translate(1, 1); | ||
} | ||
g2.setStroke(new BasicStroke(2)); | ||
g2.setColor(Color.BLACK); | ||
if (getModel().isRollover()) { | ||
g2.setColor(Color.BLACK); | ||
} | ||
int delta = 6; | ||
g2.drawLine(delta, delta, getWidth() - delta - 1, getHeight() - delta - 1); | ||
g2.drawLine(getWidth() - delta - 1, delta, delta, getHeight() - delta - 1); | ||
g2.dispose(); | ||
} | ||
} | ||
|
||
private final static MouseListener buttonMouseListener = new MouseAdapter() { | ||
public void mouseEntered(MouseEvent e) { | ||
Component component = e.getComponent(); | ||
if (component instanceof AbstractButton) { | ||
AbstractButton button = (AbstractButton) component; | ||
button.setBorderPainted(true); | ||
} | ||
} | ||
|
||
public void mouseExited(MouseEvent e) { | ||
Component component = e.getComponent(); | ||
if (component instanceof AbstractButton) { | ||
AbstractButton button = (AbstractButton) component; | ||
button.setBorderPainted(false); | ||
} | ||
} | ||
}; | ||
} |
Oops, something went wrong.