Skip to Main Content

Java Development Tools

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Invalid MAGIC number in jar file

mh379860lyNov 30 2012 — edited Nov 30 2012
HI Gentlemen,

I just compiled a java file into a class file and then set up a jar file with that one single class. Manifest indicates that the Java version is 1.7.0 as is any other development tool. Now I am inspecting the file with my hex editor and it does not contain CAFEBABE as a magic number. However, a legacy jar file in an Applet sample code has it and works correctly. It was as well with my JDK 1.7.0 compiled. What can be wrong with my method? JDeveloper does not accept the jar when I want to deploy and call the applet.

Please help if you can.

Many thanks in advance, kindly regards

Miklos HERBOLY
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 28 2012
Added on Nov 30 2012
6 comments
5,396 views