Limitations of CertMagic

Hi! As I documented in this post, I was using a Caddy plugin to save certificate information in a database. This very roughly worked as follows:

  • Added an event fired when a certificate is obtained
  • Caddy plugin listens for that event and saves details to a database

Unfortunately, with certificates now obtained by CertMagic, I’m in a tricky situation. I can’t use a Caddy plugin, as CertMagic doesn’t know about Caddy and can’t emit an event. Additionally, I can’t make a CertMagic plugin, as those don’t exist.

Any ideas? My only thought is to build my database integration directly into CertMagic.

Matt to the rescue!

Most Caddy events related to TLS are emitted from this function now:

However, you should still be seeing the event as before:

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.