We need a method to get TlsStream's client cert
- Dominant language
- Rust
- Stars
- 172
- Forks
- 49
- PR merge metrics
- No merged PRs in 30d
Description
In the case of X509 client verification, we want to get the certificate of client to extract some extra info(email, name, ...)
but ServerSession is not for public use. https://github.com/async-rs/async-tls/blob/master/src/server.rs#L20
Is it a good idea to have some code like:
```rust
impl TlsStream {
pub fn peer_certificates(&self) -> Option> {
self.session.get_peer_certificates()
}
}
```
Contributor guide
No contributing guide indexed for this repository
Research direction
Read src/server.rs around line 20 and inspect the TlsStream and ServerSession entry points referenced in the issue. Verify how peer certificates are exposed by the underlying session and whether the proposed public API fits the existing visibility and ownership model. Done means a supported way for callers to retrieve the verified client certificate data.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- security
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100