my dog learned polymorphism*
The moose likes Applets and the fly likes Signed Applet    Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Java » Applets
Bookmark "Signed Applet    " Watch "Signed Applet    " New topic
Author

Signed Applet

Pt Patel
Greenhorn

Joined: Mar 05, 2009
Posts: 11
Hi,

I want to make "import certificate" easy on client side for my signed applet.
Currently I am using keytool import command in windows to import the certificate.

Is there any way to import the certificate without using command prompt, I mean using the web browser.
Current I am using IE and Mozilla Firefox in windows.

Later on I required to test on Mac and Linux as well. Please also let me know, where can I get the information to import certificate in the web browser in Mac and Linux?

Thanks in advance.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41634
    
  55
If the applet is signed, then the client does not have to import any certificate - she has to accept it. The browser will open a dialog showing the details, and then present a choice of accepting or rejecting it. So what exactly are you trying to accomplish?

As an aside, Firefox is the same on all platforms. So if you have a certificate import procedure for Firefox Windows, it's also good for other platforms that run Firefox. It'll be different for Opera, OmniWeb, iCab, Safari, Konqueror, KHTML etc. of course.


Ping & DNS - my free Android networking tools app
Pt Patel
Greenhorn

Joined: Mar 05, 2009
Posts: 11
Thanks for reply.Our applet will Browse the file on client PC and write the data in the selected file on client PC.

On my windows XP machine, it is working fine. I performed the following steps:

Import certificate as a trusted certificate.
keytool -import -alias clientcer –file mycertificate.cer -keystore clientstore -storepass clientpass

Then Run the applet in the Firefox -> it will ask to accept the certificate -> Accept it and working fine.

Now I tried on Mac in Safari. On the first time it asks to "Trust", I pressed "Trust" button and does not appear anything on the applet.
So I thought that the above import command is necessary. I am not much familiar of Mac but tried to run the above command but it does not run that command.

In short:
I want to run my signed applet on Mac and Linux on remote PC(any client PC) with minimum efforts( or easy to use).
Please give me some hints or some link on the net for that. I will be happy if we can run signed applet on client side without running "keytool import" command.

Thanks.


Pt Patel
Greenhorn

Joined: Mar 05, 2009
Posts: 11

Please..Please...give some hints or useful links....

I want to run my signed applet in a remote Mac and Linux PC. When I open the page, it is also asking me to accept the applet and "Trust", when I press "trust" button it does not display.
We tried in Mac safari and Firefox. And in Linux Firefox.

I have few questions:
Will Signed Applet made in Sun JDK will work in Apple's Java on Mac?
Will Signed Applet made in Sun JDK will work in GNU Classpath Java on Linux?

Please give me some useful links at least !!!

Thanks.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41634
    
  55
In general, certificates made with the Sun JDK should work on other platforms. No importing is necessary, just confirming it in the dialog the browser shows.

As for Safari, are there any (error) messages in the Java Console, the Console Log, or the System Log? (The latter two can be opened using the "Console" application.)
Pt Patel
Greenhorn

Joined: Mar 05, 2009
Posts: 11
Thank you for reply,

The Java Console does not give any error.

Please let me know,
whether the Apple Java and GNU Classpath will be fine for signed applet made with Sun JDK?
I have used Theme with JDesktopPane and JInternalFrame in my Applet, is there any issue with this?

Please at least give some hints to get it run in Mac and Linux.

Thanks once again for all your help.

Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41634
    
  55
The Java Console does not give any error.

What about the other logs files I mentioned? If you don't know what those are then you will need to learn about them if you're serious about supporting OS X.

Please let me know, whether the Apple Java and GNU Classpath will be fine for signed applet made with Sun JDK?

I already said that it should work; definitely on OS X. If you want advice on where to focus your efforts, then I'd say to forget about GNU Classpath (and JVMs such as Sable and Kaffe), and test the Sun JDK for Linux instead. The installed base of GNU Classpath is just way too small to worry about (and it's not even a complete implementation of the class libraries).

I have used Theme with JDesktopPane and JInternalFrame in my Applet, is there any issue with this?

What do you mean by "issue"? If it works as you expect it to, then I'd assume there isn't.
 
jQuery in Action, 2nd edition
 
subject: Signed Applet