Repository navigation
Conversation
There was a problem hiding this comment.
🟡 Changes recommended
The new regression needs a MesaLink guard because that backend does not emit the certificate fields it asserts.
1 open issue
What changed in this PR
This PR fixes temporary resource leaks in bRPC’s SSL diagnostic output.
Changes:
- Adds scoped ownership for peer certificates and diagnostic BIO buffers.
- Adds an in-memory TLS regression checking certificate release after repeated diagnostic output.
| File | Description |
|---|---|
test/brpc_ssl_unittest.cpp |
Adds regression coverage for peer-certificate cleanup. |
src/brpc/details/ssl_helper.cpp |
Automatically releases certificate references and BIO buffers. |
Review effort: Balanced
There was a problem hiding this comment.
Warning
Copilot couldn't run its full agentic review because it didn't start before the timeout. Make sure your repository has a runner available, or add a copilot-code-review.yml file specifying one with the runs-on attribute. See the docs for more details.
Copilot review overview
3 open issues
SSLv23_method()has long been deprecated in OpenSSL (kept as a compatibility alias in many… · NewX509_get_ex_new_index()allocates a new global ex-data index each time it’s called; doing this… · New This can be simplified by checking the owning pointer directly (e.g.,if (!bio) return;) and then… · New
1 resolved since last review
Review effort: Lite
There was a problem hiding this comment.
Warning
Copilot couldn't run its full agentic review because it didn't start before the timeout. Make sure your repository has a runner available, or add a copilot-code-review.yml file specifying one with the runs-on attribute. See the docs for more details.
Copilot review overview
2 open issues
3 resolved since last review
Review effort: Lite


What problem does this PR solve?
Problem Summary:
Printing an SSL session obtains an owning peer-certificate reference, and printing a certificate allocates a BIO. Repeated diagnostic output retains both resources.
What is changed and the side effects?
Changed:
Side effects:
Check List: