Re: Anyone developing Java ME on OS X?
[email protected] Sun, 20 Jul 2008 09:28:19 PDT
| Newsgroups | gmane.comp.java.sun.kvm |
|---|---|
| Message-ID | <16147744.37381216571339830.JavaMail.tomcat@sdcst12.sjc.collab.net> |
Hi Chris, I'll take a shot at explaining the preverifier's purpose. In java (SE) code is loaded into the VM. This code can come from a bounty of locations because special classloaders can be made to pull from across the net or automagically generate the code on the fly. This can be very risky business, and as such the Java specification requires that the JVM verify the code before running it. This verify process checks to insure that there has been no alteration of the bytecode, and that it meets all the requirements for security including opcode formation, and stack over/underflow checks. But this is for SE which runs on desktop computers with cycles to spare and memory to load all this wonderful verification code, not to mention a classloader. So JavaME wants to be as safe and secure as SE and to meet that end we need to run through the same verification process.... only for ME it is done on the desktop before it is loaded to the device, and thus the name PREverifier. But this process is not just a simple check that reads the code and reports errors, the javaME preverifier must also update the bytecode with some information that can be checked on the handset by the JVM there, so there is still a bit of the verification process that must happen on the device, but this code in the Preverifier does as much of the heavy lifting as possible so that the device can run some much simpler checks and be sure that they have not been spoofed. The question that we have asked for years however is why must the Preverifier be a platform specific EXE file, and not just another Java application. This would make it so much easier to build and port the WTK or other mobile tools to Linux and Mac where a sizable portion of developers like to work. It is sad that Unix is the platform which is last to have the WTK ported to if at all, and it is the OS that Sun helped build, and is their hardwares' primary OS. Hope that helps provide an understanding of Preverifier. -Shawn [Message sent by forum member 'sfitzjava' (sfitzjava)] http://forums.java.net/jive/thread.jspa?messageID=287918 =========================================================================== To unsubscribe, send email to [email protected] and include in the body of the message "signoff KVM-INTEREST". For general help, send email to [email protected] and include in the body of the message "help".