Can I get the source code from jar file?

W

www

Hi,

I am running somebody's program. He gives me a script to run the program
and all the bunch of jar files the program needs. He didn't give me the
*.java file at all. I am wondering if I can get those *.java files from
all the *.jar files.

Thank you.
 
S

swing

Hi,

I am running somebody's program. He gives me a script to run the program
and all the bunch of jar files the program needs. He didn't give me the
*.java file at all. I am wondering if I can get those *.java files from
all the *.jar files.

Thank you.

Extract those jar files using winwar or an other program.
The owner might have included the source files.
 
W

www

Thank you all. I checked with:

jar tf jarfilename.jar

It is all *.class files, not *.java files. So the author didn't include
*.java files when he created these jar files.
 
U

usenetuser

Thank you all. I checked with:

jar tf jarfilename.jar

It is all *.class files, not *.java files. So the author didn't include
*.java files when he created these jar files.

You could use something like JAD (along with FrontEnd Plus) to
decompile the .class files to .java files. You won't get his
exact .java files (i.e. it won't include comments, for example) but as
near as you're going to get without the originals.... so long as he
hasn't obfuscated the original.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,754
Messages
2,569,527
Members
45,000
Latest member
MurrayKeync

Latest Threads

Top