• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Digitally Signing Applets

 
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm very new to both java and making applets, so please bear with me.

I need to digitally sign an applet so that it can read and write files on the local system. The applet downloads a file that the user selects and then the user can also upload files to a server.

However, I have absolutely no idea how to go about doing this, and everything that I've read so far is pretty cryptic and gets far to technical for my level of understanding. So far I've looked at http://faq.javaranch.com/java/HowCanAnAppletReadFilesOnTheLocalFileSystem and its references, and tried searching google for a simple tutorial.

Could anyone please define that steps that are necessary to signing an applet, or point me in the right direction? Also, I'm developing the applet on in the Eclipse IDE, so if there is a way to sign applets within eclipse, that would be fantastic .

Thanks in advance for any help!
-Lance
 
Ranch Hand
Posts: 405
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

You need to get a signature ID from one of the various companies that
distribute them. What this gives you is a private key and a public
key. You sign your applets with the private key and give out your
public key so that everyone else can decrypt your private key.
Attached is a URL for one such company:

http://verisign.netscape.com

brief steps for signing a java applet:
1) you develop applet
2) get signature ID from above URL
3) use private key to sign your applet
4) clients get your public key and enter it in their database
5) run applet

To generate a key, use the below java command from command prompt/console

keytool -genkey -alias ujjwal -keyalg -RSA


After this, you will need a digital certificate, if you are looking for free certificates then you will find many site offering free certificates on google.
 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Note that for development purposes you can also generate your own certificate (step 2 in Ujjwal's list) instead of getting an official one. That's done using the "keytool" executable that comes with the JDK; the process is described in the articles linked in that FAQ page.
 
reply
    Bookmark Topic Watch Topic
  • New Topic