Solved

Adding a certificate to Trusted Certificates

Posted on 2007-11-20
6
6,194 Views
Last Modified: 2010-04-13
I want to push out a Java certificate for an application to all our workstations.  It needs to be added to trusted certificates.  I tried using keytool.exe, but it seems no matter what I do, it always asks for a password and it always prompts for "do you want to trust this certificate?"  Also, after I import the certificate using keytool, it seems that it imported, but it never ends up in Trusted Certificates and it doesn't allow the application to work (a window pops up saying that the digital signature has been verified and do you want to run the app.).  The command I am using is...

keytool -import -trustcacerts -file c:\mycertfile.cer

I'm not locked into using keytool, I am open to whatever way will work.

Is there an automated way to add this certificate to Java Trusted Certificates?
0
Comment
Question by:bpl5000
6 Comments
 
LVL 23

Expert Comment

by:rama_krishna580
ID: 20320329
0
 
LVL 5

Author Comment

by:bpl5000
ID: 20320835
Maybe I should be more specific.  If you go into Control Panel and click on Java, the Java Control Panel will come up.  In the Java Control Panel, click on the Security tab and click on the Certificate button.  Here you will see a list of trusted sites.  I want to know if there is an automated way to import a certificate into Trusted Certificates.  When a certificate is entered, the info is kept in this file...

"C:\Documents and Settings\<UserAccount>\Application Data\Sun\Java\Deployment\security\trusted.certs"

This is not a text file so I can't append to it.  I could overwrite it with my file, but then the workstation would lose other entries that might exist.  Does anyone have any idea how to import a certificate into Java?
0
 
LVL 92

Accepted Solution

by:
objects earned 500 total points
ID: 20323183
> Does anyone have any idea how to import a certificate into Java?

using keytool, as you already are.
0
Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

 
LVL 5

Author Comment

by:bpl5000
ID: 20323887
objects, can you give me an example?  When I use keytool, it seems to import it successfully, but then it still doesn't allow the application to work and I cannot see it in the Trusted Certificates in the Java control panel.  If I import it from the Java control panel, then the application works fine.  Also, can I fully automate the process using keytool (not have to answer prompts)? The -noprompts switch doesn't seem to work for me.   If so, can you show me an example?
Thanks!
0
 
LVL 4

Expert Comment

by:TheMajestic
ID: 20325688
hi,
 hope this will help u a lot.

cwiki.apache.org/GMOxDOC12/certificate-properties-file-realm.html
help.globalscape.com/help/secureserver2/Importing_a_certificate_int.htm
www.lbl.gov/imapssl/add-trusted-certificate-authority.html
www.akadia.com/services/ssh_test_certificate.html
help.globalscape.com/help/secureserver2/Creating_Certificates.htm
0
 
LVL 3

Expert Comment

by:Orbsol
ID: 24978413
I have exactly the same problem as described above. Can bpl5000 explain how he/she achieved this as the "accepted solution" does not cover it.
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
check java version using powershell 13 170
use lov values 2 61
ejb mdb examples 1 7
Eclipse Java import and method not resolved 4 48
For beginner Java programmers or at least those new to the Eclipse IDE, the following tutorial will show some (four) ways in which you can import your Java projects to your Eclipse workbench. Introduction While learning Java can be done with…
Introduction This article is the last of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers our test design approach and then goes through a simple test case example, how …
Video by: Michael
Viewers learn about how to reduce the potential repetitiveness of coding in main by developing methods to perform specific tasks for their program. Additionally, objects are introduced for the purpose of learning how to call methods in Java. Define …
This tutorial will introduce the viewer to VisualVM for the Java platform application. This video explains an example program and covers the Overview, Monitor, and Heap Dump tabs.

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question