1

I have to add to a trust list my self signed certificate ,but now I need to remove it

I am looking for the proper way to do so, without braking the system

This is the way I added:

I copied the certificate at this location:

/usr/local/share/ca-certificates

the I run the command:

update-ca-certificates

Now I need to remove it, because I need to create a wild card certificate and again add it to a trust list

I can see the certificate in:

/etc/ssl/certs

and I've been thinking to just remove it from both locations and run again

update-ca-certificates

but I am not sure, if this will work

Thank you

xlameee
  • 11

2 Answers2

1

If you want to remove your certificate, here is the steps that you should follow:

  1. remove your certificate file from /usr/local/share/ca-certificates
  2. run update-ca-certificates -f

According to the man pages for update-ca-certificates, add the -f switch do the job for you:

-f, --fresh
          Fresh updates.  Remove symlinks in /etc/ssl/certs directory.

This will recreate a new ca-certificate.crt file without your custom root CA certificate and remove the symlink associated with it from /etc/ssl/certs/.

MHM
  • 111
-1

I manually edited the file /etc/ssl/certs/ca-certificates.crt

But I'm not confident this is the correct approach, however removing the file /usr/local/share/ca-certificates did not remove the cert from /etc/ssl/certs/ca-certificates.crt