How to replace the Vault self-signed certificate with a Internal CA / External CA certificate.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements

Welcome Idira to LIVEcommunity!

Our community just got stronger! Explore new identity security resources, connect with experts, and discover more ways to learn and collaborate.

Meet Idira

How to replace the Vault self-signed certificate with a Internal CA / External CA certificate.

L6 Presenter

Create the Vault.csr (Certificate Request)

 

On the Vault run:

CACert.exe request /ReqOutFile Vault.csr /CommonName "WIN-4SLA3N5U1V6.localdomain.local" /SubjAlt "DNS:WIN-4SLA3N5U1V6.localdomain.local, IP:10.10.1.24"

 

This will replace the certificate in your ServerPrivateKey= location specified in the dbparm.ini. It is a good idea to backup and also temporarily change the location just to generate the CSR.

Don't forget to change back the location after you have generated the request.

 

To create the certificate, copy the Vault.csr to the CA (Certificate Authority).

On the CA server run:

certreq -submit -attrib "CertificateTemplate:SubCA" Vault.csr Vault.cer

 

Download the root certificate and the Vault.cer to the Vault server.

 

Create a location where the root certificate needs will be installed (Example C:\Root\)

Add the location to the TrustedCAPath in the dbparm.ini (TrustedCAPath=C:\Root\root.cer)

 

Install the root certificate

c:\Program Files (x86)\PrivateArk\Server>CACert.exe setca /Add root.cer

 

Install the Vault.cert:

 

CACert.exe install /CertFileName Vault.cer

 

Replace the old Server.pvk with the new Server.pvk

 

Restart the Vault

 

7 REPLIES 7

L4 Transporter

Good idea to have this here 🙂

 

The next steps would be to use this certificate. In all components, edit the Vault.ini , specify the FQDN of the Vault in ADDRESS and uncomment/set the two parameters.

ADDRESS=WIN-4SLA3N5U1V6.localdomain.local PORT=1858 PREAUTHSECUREDSESSION=Yes TRUSTSSC=No

Finally restart the right service to reload the vault.ini.

This way, each component will verify that the Vault it is connecting to is the right one by verifying the Vault's certificate. Of course, each component needs to trust the CA chain the certificate comes from.

 

Last thing, add a reminder to all vault admins' calendar so you don't forget to renew certificate before it expires otherwise you'll end up with a complete production mess.

L6 Presenter

@Sebastien Siegl​ ,

 

Thanks! And thank you for your addition too.

 

L0 Member

Out of curiosity, why would you sign the request so it becomes a subordinate CA? That certificate template allows the Vault to sign certificate requests directly and those certificates would be trusted by anything that trusts the Root CA.

 

Is there a specific EKU that the Vault needs? Usually in these types of applications the Server Authentication EKU is sufficient.

I am pretty sure that he used the SubCA template just because it was handy. I have just run through this and used a version of the standard "Computer" template furnished with Windows Server 2008 and that appears to work fine. I am also reasonably sure that you don't want your vault to moonlight as a SubCA.

😉

The option "PREAUTHSECUREDSESSION=Yes" seems to have prevented my PVWA from starting. Left it off and it works fine with "TRUSTSSC=no"

 

L0 Member

Thanks Jeff. I was able to place a standard Web Server (Server Auth with Signing) template certificate on the vault and it has functioned without a problem. We have a multi-tiered CA so I had to bundle the root and intermediate into a single cer file. (If you arent familiar with bundling root and intermediates this is a concise link https://support.globalsign.com/customer/en/portal/articles/1224583-root-intermediate-certificate-bun...) For those that are interested it here is the procedure:

For the full parameter options for the CACert tool, please refer to the Privileged Account Security Implementation Guide under section "CACert".

 

Before making any changes, you will want to backup your existing certificate files according to the following parameters in the DBParm.ini:

- ServerCertificateFile

- TrustedCAPath

If any troubles arise, you can then restore these files.

 

You can find the CACert executable in the PrivateArk Server install directory, \Program Files (x86)\PrivateArk\Server.

In addition, backup the output of "cacert show" and "cacert setca /list" commands to a text file for later reference.

 

Before beginning please stop the vault service.

 

From an elevated command prompt, you can run something like the following:

CACert.exe Request /ReqOutFile Vault.csr /CommonName "vault.example.com" /SubjAlt "DNS:alsovault.example.com, IP:192.0.2.1"

 

Note that after you run this the Vault will not be able to start, as it will not have a valid certificate that matches.

 

Then you can take the Vault.csr file to your CA to get the certificate. When you have the certificate, run the following to import it:

CACert.exe Install /CertFileName Vault.crt 

L3 Networker

Does this work when the vault has been hardened or is this done as a prerequisite ?

 

  • 6636 Views
  • 7 replies
  • 0 Likes
Like what you see?

Show your appreciation!

Click Like if a post is helpful to you or if you just want to show your support.

Click Accept as Solution to acknowledge that the answer to your question has been provided.

The button appears next to the replies on topics you’ve started. The member who gave the solution and all future visitors to this topic will appreciate it!

These simple actions take just seconds of your time, but go a long way in showing appreciation for community members and the LIVEcommunity as a whole!

The LIVEcommunity thanks you for your participation!