OPNsense Forum

English Forums => 25.1, 25.4 Series => Topic started by: MildDisaster on March 08, 2025, 08:41:35 PM

Title: Unable to delete orphaned certificate
Post by: MildDisaster on March 08, 2025, 08:41:35 PM
This is 25.1.2

Setup HAProxy to trial something. In the process created a certificate for the public service.

Decided not to use HAProxy, made sure to delete the service/pool/server manually first (probably not required, karma if anything).
Then uninstalled the HAProxy.

Went to go remove the certificate from trusts, but it is throwing an error.

Item in use by
HAProxy - ####### service {HAProxy.frontends.frontend.8677cf50-aa25-4cc7-b8d1-b9c3131de795}

Not sure how to remediate this, please advise, thank you.
Title: Re: Unable to delete orphaned certificate
Post by: MildDisaster on March 13, 2025, 03:22:46 AM
Given no response on this topic; is there a bug tracker, or an issue ticket system I can submit this too ?

Its not blocking type issue, but perhaps the plugin maintainer might be interested, or maybe the UI team for better dealing with orphaned items.
Title: Re: Unable to delete orphaned certificate
Post by: newsense on March 13, 2025, 04:02:41 AM
You can try opening an issue on github opnsense/plugins
Title: Re: Unable to delete orphaned certificate
Post by: tmueko on July 03, 2025, 11:22:50 AM
I have the same problem but in core: I created some certificates and added them to a revocation-list. Denn I deleted CA and CRL. Now I have certs in use which cant't be deleted:
Item in use by
cert - <CN> {crl.cert}
find / -name crl.cert returned nothing.
Title: Re: Unable to delete orphaned certificate
Post by: bradz71 on July 05, 2025, 11:18:26 PM
@MildDisaster

Just ran into something similar myself.  Here is what worked for me.  Based on your error message, you have an orphaned frontend from and old HAProxy installation.  Foolproof way to fix is to reinstall HAProxy, then browse to the frontend configs.  Delete the old frontend config. Check System: Trust: Certificates and remove old certificate.  Uninstall HAProxy.  Done :)   Hope this helps.
Title: Re: Unable to delete orphaned certificate
Post by: Patrick M. Hausen on July 05, 2025, 11:41:23 PM
Or download configuration backup, open the XML in an editor, carefully remove the entire HAproxy section, re-upload configuration.