Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

httpcaddyfile: Disabling OCSP stapling for both managed and unmanaged #4589

Merged
merged 1 commit into from
Feb 19, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions caddyconfig/httpcaddyfile/tlsapp.go
Original file line number Diff line number Diff line change
Expand Up @@ -301,6 +301,11 @@ func (st ServerType) buildTLSApp(
tlsApp.Automation.RenewCheckInterval = renewCheckInterval
}

// set whether OCSP stapling should be disabled for manually-managed certificates
if ocspConfig, ok := options["ocsp_stapling"].(certmagic.OCSPConfig); ok {
tlsApp.DisableOCSPStapling = ocspConfig.DisableStapling
}

// if any hostnames appear on the same server block as a key with
// no host, they will not be used with route matchers because the
// hostless key matches all hosts, therefore, it wouldn't be
Expand Down
7 changes: 5 additions & 2 deletions caddytest/integration/caddyfile_adapt/global_options.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
}
acme_ca https://example.com
acme_ca_root /path/to/ca.crt
ocsp_stapling off

email [email protected]
admin off
Expand Down Expand Up @@ -61,7 +62,8 @@
"module": "internal"
}
],
"key_type": "ed25519"
"key_type": "ed25519",
"disable_ocsp_stapling": true
}
],
"on_demand": {
Expand All @@ -71,7 +73,8 @@
},
"ask": "https://example.com"
}
}
},
"disable_ocsp_stapling": true
}
}
}