Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Building from source? #6

Closed
clintgibler opened this issue Nov 16, 2016 · 3 comments
Closed

Building from source? #6

clintgibler opened this issue Nov 16, 2016 · 3 comments

Comments

@clintgibler
Copy link

Hey there. Thank you for releasing this tool-- it seems quite useful and I appreciate the documentation in the README!

My apologies if this is an obvious question, but I'm having some difficulty building this tool from source.

  • I see the JARs one can download via the Releases tab, but I'd like to build from source if possible.
  • I see ant/antbuild.xml - but it seems to expect existing .class files to be in bin/, which it then zips up with JARs in libs/ into the final JAR.

Progress Building from Source

I believe I'm close, as I've compiled the Java source into bin/ with:

$ javac -d bin/ -cp src/burp/*

Then the JAR can be built with:

$ ant -f ant/antbuild.xml

Which successfully builds output/JavaDeserializationScanner_dev.jar.

Observed Errors

However, when I try to add this JAR via Burp Extender, I get the following error:

java.lang.ClassNotFoundException: burp.BurpExtender
	at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
	at java.lang.Class.forName0(Native Method)
	at java.lang.Class.forName(Class.java:348)
	at burp.p3e.a(Unknown Source)
	at burp.p3e.<init>(Unknown Source)
	at burp.vz.a(Unknown Source)
	at burp.dre.run(Unknown Source)
	at java.lang.Thread.run(Thread.java:745)

Environment

  • java - openjdk version "1.8.0_111"
  • javac - javac 1.8.0_111
  • OS - Ubuntu 14.04
  • Burp Suite Pro version 1.7.02beta

Any advice would be much appreciated, thanks!

@federicodotta
Copy link
Owner

Hi! Strange error. It seems that Burp does not recognise its own interfaces and classes. Maybe is only an error in classes tree.

You can try to simply compile the project by importing it in Eclipse and then compiling it with integrated ANT compiler. In this way it works for me.

If you prefer, now there is also a pom file and you can use it to compile the project with Maven.

Do you need more help?

Federico

@clintgibler
Copy link
Author

Hi! Thanks for your answer and sorry for my response delay.

I may be missing something obvious- you mention a pom file, but I don't see a pom.xml or project.xml in the repo.

If you wouldn't mind giving the one or two shell commands to build this project from the command line I would much appreciate it!

@federicodotta
Copy link
Owner

Hi! The easiest way to compile the project is to import everything in Eclipse (folders "ant", "libs" and "src/burp", for "src/burp" you have to create a folder named "burp" in the "src" folder of the project and put the source files in there) and using ANT to compile. After having imported everything in Eclipse, you have to add all libraries in "libs" folder to the project, by clicking with the right button on the project and selecting "properties". Then go to "Java Build Path" -> "Libraries" -> "Add JARs" and add all the JAR in the libs folder. Then click Apply and exit. Now, to create the plugin JAR file with ANT you have only to click with the Right Button on the file "antbuild.xml" in the "ant" folder and select "Run As" -> "Ant build". I hope I was clear.

Have a nice day!
Federico

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants