Home Upgrade Search Memberlist Extras Hacker Tools Award Goals Help Wiki Contact

Installing Certificate PFX - Linux

Firstly, I know most of the Ub3R's here will know the process for this, but for any newbie that might want to know.. If you already have your Cert setup then it want to be exported into a PFX format and contain the Private Key.

Open a Terminal windows and browse to the location of the newly copied PFX file. For me it was “Term/Downloads/Certificates“.

In the command Windows we now use the “openssl” tool to perform a couple of tasks, the first to extract the “.pem” or key file, then second the actual certificate “.crt” file.

Export the Private Key
openssl pkcs12 -in Root.pfx -nocerts -out Root.pem -nodes

Export the Certificate
openssl pkcs12 -in Root.pfx -nokeys -out Root.crt -nodes

These commands will ask for the PFX password and then export the two files. Now we have the root certificate and do the same

Export the Private Key
openssl pkcs12 -in Website.pfx -nocerts -out Website.pem -nodes

Export the Certificate
openssl pkcs12 -in Website.pfx -nokeys -out Website.crt -nodes

Now we have the individual files we need to import them into the system by using the following commands from the same location in the Terminal window:

Import Root Certificate
sudo cp Root.crt /usr/local/share/ca-certificates/Root.crt

Import Website Certificate
sudo cp Website.crt /usr/local/share/ca-certificates/Website.crt

These will then import successfully, but to be able to bypass the security checks for the Certificates, we need to run one last step, which is to update the certificate cache.

sudo update-ca-certificates

That now completes adding the certificate to you machine.
[Image: newnew3.gif]


Possibly Related Threads...
Thread / Author Replies Views Last Post
by OmniscientJun 17, 2026 07:55 AM 15 343 Jun 17, 2026 07:55 AM
Last Post: Omniscient
[Kali] by perkioDec 6, 2024 02:30 AM 5 397 Dec 6, 2024 02:30 AM
Last Post: $!uo2H%gE#
by YonBrenner85Oct 1, 2022 05:42 AM 3 317 Oct 1, 2022 05:42 AM
Last Post: 2xTheTap115