• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Loading Dlls

 
Pradip Bhat
Ranch Hand
Posts: 149
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I have an applet which includes 3 jars files.In addition how to include DLLs in an applet?Does my applet has to be signed for doing that?
Thanks
Rahul
 
Maulin Vasavada
Ranch Hand
Posts: 1873
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi rahul
can you clarify your question more?
and just a pointer- if you plan to use DLL then you assume that your applet is only going to be use on Windows OS...right? because Unix OS have .so files instead of DLL...
i'm not sure but i guess if you want DLL access you have to have some permissions on the client machine and you would mostly end up signing the applet...
this might be helpful...
regards
maulin
 
Tim Holloway
Saloon Keeper
Posts: 18359
56
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
DLLs work ONLY under Windows. This means you must want your applet to never run on Macintoshes, Linux machines, machines running Solaris, or anything BUT Windows.
Java is OS-independent, and since DLLs are quite OS-dependent, there is no direct support. There is indirect support via JNI - the Java Native Interface. Because use of JNI makes an applet OS-dependent and because once in JNI you lose all security safeguards, you can only use JNI if you are distributing a security signed applet.
If you sign the applet and set ups its security privileges right, you can then simply have the applet download the DLLs via HTTP tunneling and copy them into the user's local filesystem. Assuming that they don't have Windows security set up to block you.
This is a lot of work and a potential security risk, so it's not something I recommmend be done if there's a more secure and OS-independent alternative.
A variation on this is to setup some sort of "install-from-the-web" process to pull down and install the DLLs. Regardless, a Java applet MUST be signed before it can call code in the DLLs.
 
Sumeet Gaikwad
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dear Rahul,
Can you put one file in user's home before calling the applet.??
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic