Struct sozu_lib::https::HttpsListener
source · pub struct HttpsListener { /* private fields */ }
Implementations§
source§impl HttpsListener
impl HttpsListener
pub fn try_new( config: HttpsListenerConfig, token: Token ) -> Result<HttpsListener, ListenerError>
pub fn activate( &mut self, registry: &Registry, tcp_listener: Option<MioTcpListener> ) -> Result<Token, ListenerError>
pub fn create_rustls_context( config: &HttpsListenerConfig, resolver: Arc<MutexWrappedCertificateResolver> ) -> Result<ServerConfig, ListenerError>
pub fn add_https_front( &mut self, tls_front: HttpFrontend ) -> Result<(), ListenerError>
pub fn remove_https_front( &mut self, tls_front: HttpFrontend ) -> Result<(), ListenerError>
Trait Implementations§
source§impl L7ListenerHandler for HttpsListener
impl L7ListenerHandler for HttpsListener
fn get_sticky_name(&self) -> &str
fn get_connect_timeout(&self) -> u32
source§fn frontend_from_request(
&self,
host: &str,
uri: &str,
method: &Method
) -> Result<Route, FrontendFromRequestError>
fn frontend_from_request( &self, host: &str, uri: &str, method: &Method ) -> Result<Route, FrontendFromRequestError>
retrieve a frontend by parsing a request’s hostname, uri and method
source§impl ListenerHandler for HttpsListener
impl ListenerHandler for HttpsListener
fn get_addr(&self) -> &StdSocketAddr
source§impl ResolveCertificate for HttpsListener
impl ResolveCertificate for HttpsListener
type Error = ListenerError
source§fn get_certificate(
&self,
fingerprint: &Fingerprint
) -> Option<CertifiedKeyWrapper>
fn get_certificate( &self, fingerprint: &Fingerprint ) -> Option<CertifiedKeyWrapper>
return the certificate in both a Rustls-usable form, and the pem format
source§fn add_certificate(
&mut self,
opts: &AddCertificate
) -> Result<Fingerprint, Self::Error>
fn add_certificate( &mut self, opts: &AddCertificate ) -> Result<Fingerprint, Self::Error>
persist a certificate, after ensuring validity, and checking if it can replace another certificate
source§fn remove_certificate(
&mut self,
fingerprint: &Fingerprint
) -> Result<(), Self::Error>
fn remove_certificate( &mut self, fingerprint: &Fingerprint ) -> Result<(), Self::Error>
Delete a certificate from the resolver. May fail if there is no alternative for
source§fn replace_certificate(
&mut self,
opts: &ReplaceCertificate
) -> Result<Fingerprint, Self::Error>
fn replace_certificate( &mut self, opts: &ReplaceCertificate ) -> Result<Fingerprint, Self::Error>
Short-hand for
add_certificate
and then remove_certificate
.
It is possible that the certificate will not be replaced, if the
new certificate does not match add_certificate
rules.Auto Trait Implementations§
impl !RefUnwindSafe for HttpsListener
impl !Send for HttpsListener
impl !Sync for HttpsListener
impl Unpin for HttpsListener
impl !UnwindSafe for HttpsListener
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more