File tree Expand file tree Collapse file tree 1 file changed +13
-0
lines changed
Expand file tree Collapse file tree 1 file changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -255,6 +255,19 @@ func (p *Proxy) setupTLSServer() error {
255255 certChain := [][]byte {serverCertBlock .Bytes }
256256 certChain = append (certChain , chainCerts ... )
257257
258+ // Debug: log the complete certificate chain as PEM
259+ var chainPEM strings.Builder
260+ for i , certBytes := range certChain {
261+ chainPEM .WriteString (fmt .Sprintf ("--- Certificate %d ---\n " , i + 1 ))
262+ certPEM := pem .EncodeToMemory (& pem.Block {
263+ Type : "CERTIFICATE" ,
264+ Bytes : certBytes ,
265+ })
266+ chainPEM .Write (certPEM )
267+ chainPEM .WriteString ("\n " )
268+ }
269+ log .Printf ("Complete certificate chain PEM:\n %s" , chainPEM .String ())
270+
258271 // Create TLS config
259272 p .tlsConfig = & tls.Config {
260273 Certificates : []tls.Certificate {
You can’t perform that action at this time.
0 commit comments