fix: also handle ocsp requests to subpaths of /ocsp/

Signed-off-by: Florian Bauer <florian@fsrv.xyz>
This commit is contained in:
Florian Bauer
2025-01-22 20:20:17 +01:00
parent 4942df0b25
commit 95590601f5

View File

@@ -136,8 +136,11 @@ func main() {
signal.Notify(hupChan, syscall.SIGHUP)
go reloadCrlWorker(hupChan, loadCrl)
responder := cfocsp.NewResponder(source, nil)
applicationRouter := http.NewServeMux()
applicationRouter.Handle("/ocsp", cfocsp.NewResponder(source, nil))
applicationRouter.Handle("/ocsp", responder)
applicationRouter.Handle("/ocsp/", responder)
applicationRouter.HandleFunc("/crl", func(w http.ResponseWriter, r *http.Request) {
w.Header().Set("Content-Type", "application/pkix-crl")
w.Write(crl.Raw)