Repository navigation
Conversation
Add test_24 for checking OCSP stapling responses for a test certificate delivered via `openssl s_server`. - fix gnutls edge cases that escape the default verification implemented by gnuTLS itself - openssl: use the "verified cert chain" and not the "peer chain" to check OCSP trust. The difference is that the former includes the anchor certificate. For public certificates this will mostly not matter as OCSP is rarely signed by a root cert, but for private CAs this might happen.
Contributor
|
@icing matty69v from Hackerone i retested with the latest fixes that's now good ! |
There was a problem hiding this comment.
🟡 Changes recommended
Older LibreSSL compatibility, server-startup synchronization, and test capability gates need correction.
4 open findings
What changed in this PR
Strengthens OCSP stapling verification in curl’s TLS backends and adds HTTP regression tests using openssl s_server.
Changes:
- Adds tests for missing, unsuccessful, unknown, revoked, and valid OCSP responses.
- Expands GnuTLS response validation.
- Uses OpenSSL’s verified certificate chain for OCSP trust checks.
| File | Description |
|---|---|
| tests/http/testenv/certs.py | Exposes certificate serial numbers for OCSP fixtures. |
| tests/http/test_24_ocsp.py | Adds OCSP server fixtures and regression cases. |
| tests/http/Makefile.am | Includes the new test in distributions. |
| lib/vtls/openssl.c | Switches OCSP verification to the verified chain. |
| lib/vtls/gtls.c | Validates OCSP response and peer-certificate status. |
🧠 Review effort: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
- cope with old libressl versions - skip test on better precondition
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


Add test_24 for checking OCSP stapling responses for a test certificate delivered via
openssl s_server.