[−][src]Struct udp_dtls::DtlsAcceptorBuilder
A builder for DtlsAcceptor
s.
With this builder you can configure the following DTLS properties:
- The identity to be used for client certificate authentication
- Adding and enabling the the DTLS extension 'use_srtp'
- Configuring min/max supported DTLS versions
Methods
impl DtlsAcceptorBuilder
[src]
pub fn min_protocol_version(
&mut self,
protocol: Option<Protocol>
) -> &mut DtlsAcceptorBuilder
[src]
&mut self,
protocol: Option<Protocol>
) -> &mut DtlsAcceptorBuilder
Sets the minimum supported protocol version.
A value of None
enables support for the oldest protocols supported by the implementation.
Defaults to Some(Protocol::Dtlsv10)
.
Underlying SSL
This will be used for setting the ssl options witch corresponds to SSL_CTX_set_options
.
pub fn max_protocol_version(
&mut self,
protocol: Option<Protocol>
) -> &mut DtlsAcceptorBuilder
[src]
&mut self,
protocol: Option<Protocol>
) -> &mut DtlsAcceptorBuilder
Sets the maximum supported protocol version.
A value of None
enables support for the newest protocols supported by the implementation.
Defaults to None
.
Underlying SSL
This will be used for setting the ssl options witch corresponds to SSL_CTX_set_options
.
pub fn add_srtp_profile(
&mut self,
profile: SrtpProfile
) -> &mut DtlsAcceptorBuilder
[src]
&mut self,
profile: SrtpProfile
) -> &mut DtlsAcceptorBuilder
Enables the DTLS extension "use_srtp" as defined in RFC5764.
This corresponds to SSL_CTX_set_tlsext_use_srtp
.
pub fn build(&self) -> Result<DtlsAcceptor>
[src]
Creates a new DtlsAcceptor
with the settings from this builder.
Auto Trait Implementations
impl Send for DtlsAcceptorBuilder
impl Unpin for DtlsAcceptorBuilder
impl Sync for DtlsAcceptorBuilder
impl UnwindSafe for DtlsAcceptorBuilder
impl RefUnwindSafe for DtlsAcceptorBuilder
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,