Expose a few more TLS APIs

This commit is contained in:
Yuchen Wu 2024-06-17 15:13:37 -07:00 committed by Edward Wang
parent 648a6ad055
commit c0b23c6736
3 changed files with 11 additions and 1 deletions

2
.bleep
View file

@ -1 +1 @@
f70d8b77a4085cbe11b9559317f6d6e7e49914db
f87e46c90fe2f84c2ce90ac1def9f4400ae45f24

View file

@ -38,6 +38,15 @@ pub struct TlsSettings {
callbacks: Option<TlsAcceptCallbacks>,
}
impl From<SslAcceptorBuilder> for TlsSettings {
fn from(settings: SslAcceptorBuilder) -> Self {
TlsSettings {
accept_builder: settings,
callbacks: None,
}
}
}
impl Deref for TlsSettings {
type Target = SslAcceptorBuilder;

View file

@ -25,6 +25,7 @@ pub use tokio_openssl as tokio_ssl;
pub mod ext;
// export commonly used libs
pub use ssl_lib::dh;
pub use ssl_lib::error;
pub use ssl_lib::hash;
pub use ssl_lib::nid;