Hi, I was thinking that Java class files change to different compilers. So how many actual bytes change if a .java files are called a Sun JDK 1.4, 1.5 1.6 or even IBM JDK. I know that class files can differ in relation to debug information and ambiguity, but for the question that we assume that the options are the same, there is debug info, there is no dispute, if I am a MD5 Or run SHA1, then a hash on a class file compiled by JCK 1.4, which is different, if I compile it in JDK 1.5, but I'm targeting 1.4, then target JDK 1.5 ? Apart from that, a class file change is a binary, when different dependencies are used, or is asked differently that it depends on the dependency of the binary of a square file change. It is possible?
And last but not least programmatic methods are to compile version and to identify switches or one. To analyze metadata of class file which was used while compiling it?
While compiling classes and bytecodes from sources, the Java compiler has some freedom; they are rearranged the methods Repeat, and re-order the actual byte code commands, as long as the results are the same while executing the results, with constant pools (class names, method names and strings - this result also results in byte codes by different method) Ho.
So, using MD5 or similar hash to prove that two square files come from the same source is not really sensible.
Comments
Post a Comment