Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Immport SSL Certificate in RHEL using keytool

 
jaya kemmannu
Ranch Hand
Posts: 89
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Hi,


I want to Import new SSL Certificate in RedHat Linux server using keytool. Anyone know the command for the same. ?

Thanks & Regards,
Jaya
 
Tim Holloway
Saloon Keeper
Pie
Posts: 18152
52
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
keytool.

However, that's just for Java certs. If you want to install a cert for Apache, you have to edit the Apache configuration. There's also a directory in the /etc designed to hold the actual cert files, although I don't remember its exact name (which varies, depending on the RHEL version).
 
jaya kemmannu
Ranch Hand
Posts: 89
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Hi Tim,

I am supposed to use keytool only. Can you please confirm below command what i use is valid one.

/opt/java1.5/bin/keytool -import -alias alias_name -v -keystore "keystore path" -storepass "keystore password" -file "ssl certificate path".

And can you please tell me how to ensure my old certificate is valid even after new certificate is imported. IS there any command to check this ?


Regards,
Jaya
 
Peter Johnson
author
Bartender
Posts: 5852
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes, that command syntax appears to be correct. (Why do you ask, are you getting an error???)

You can check that the certificate was added by running: keytool -list -keystore "file-name" -storepass "password"
If that doesn't give you enough info, add the -v option for vebose output.

By the way, running 'keytool -help' will explain all of the options.
 
jaya kemmannu
Ranch Hand
Posts: 89
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Hi,

The command works fine in RHEL. third party who gave the certificate asked us ensure old certificate(along with new one) is also valid at our end after new one is imported. I thoought there will be some command to validate this.

Regards,
Jaya
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic