pub trait Method {
type Handshake: Handshake;
// Required methods
fn name(&self) -> &'static str;
fn initiate(
&self,
) -> Result<Self::Handshake, <Self::Handshake as Handshake>::Error>;
fn respond(
&self,
source: Option<SocketAddr>,
) -> Result<Self::Handshake, <Self::Handshake as Handshake>::Error>;
}Expand description
An authentication method: a configured factory of handshakes.
Methods are named coqui-peer-<method>; name is the <method> part and
the name under which the method’s keys are kept in the trust store.
Required Associated Types§
Required Methods§
Sourcefn name(&self) -> &'static str
fn name(&self) -> &'static str
The method name: lowercase letters, digits and -, as in KeyMaterial::method.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".