From 15fae1a55d9f5fade8d124a0d0d587f6334b61ce Mon Sep 17 00:00:00 2001 From: Robin Thellend Date: Fri, 6 Dec 2024 07:17:50 -0800 Subject: [PATCH] oops --- go.mod | 2 +- proxy/internal/sshca/sshca.go | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/go.mod b/go.mod index ded307d..ee6c09f 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/c2FmZQ/tlsproxy -go 1.23.2 +go 1.23.1 require ( github.com/beevik/etree v1.4.1 diff --git a/proxy/internal/sshca/sshca.go b/proxy/internal/sshca/sshca.go index d3dadc7..60d048a 100644 --- a/proxy/internal/sshca/sshca.go +++ b/proxy/internal/sshca/sshca.go @@ -336,7 +336,9 @@ func (ca *SSHCA) ServeCertificate(w http.ResponseWriter, req *http.Request) { http.Error(w, "internal error", http.StatusInternalServerError) return } - ca.opts.EventRecorder.Record("ssh certificate issued") + if ca.opts.EventRecorder != nil { + ca.opts.EventRecorder.Record("ssh certificate issued") + } out := ssh.MarshalAuthorizedKey(cert) w.Header().Set("cache-control", "no-store")