pub struct MoqlAdmissionAuthenticator { /* private fields */ }Implementations§
Source§impl MoqlAdmissionAuthenticator
impl MoqlAdmissionAuthenticator
Sourcepub fn new(
authority: Arc<dyn AcceptedStateAuthority>,
tenant_resolver: PeerTenantResolver,
) -> Self
pub fn new( authority: Arc<dyn AcceptedStateAuthority>, tenant_resolver: PeerTenantResolver, ) -> Self
Build with the accepted-state authority and subject→tenant resolver.
Sourcepub fn for_server(&self) -> Self
pub fn for_server(&self) -> Self
Share live authority, isolating each service’s carrier identity and replay cache.
Sourcepub fn with_server_identity_and_carrier(
self,
server_identity: MoqlServerIdentityProof,
server_carrier_node_id: [u8; 32],
) -> Self
pub fn with_server_identity_and_carrier( self, server_identity: MoqlServerIdentityProof, server_carrier_node_id: [u8; 32], ) -> Self
Install the local accepted-state identity that signs server confirmation frames. A bare authenticator remains useful for unit decision tests but cannot admit a network tunnel.
Sourcepub fn install_server_identity(
&self,
server_identity: MoqlServerIdentityProof,
server_carrier_node_id: [u8; 32],
) -> Result<(), MoqlAdmissionError>
pub fn install_server_identity( &self, server_identity: MoqlServerIdentityProof, server_carrier_node_id: [u8; 32], ) -> Result<(), MoqlAdmissionError>
Attach the local confirmation proof at the service-spawner boundary. A caller that already supplied one must agree on the same public accepted-state identity; silently replacing it would make configuration order an authentication decision.
Sourcepub fn with_timeout(self, timeout: Duration) -> Self
pub fn with_timeout(self, timeout: Duration) -> Self
Override the admission exchange timeout (bounded slowloris window).
Sourcepub async fn accept(
&self,
conn: &Connection,
) -> Result<AdmittedMoqPeer, MoqlAdmissionError>
pub async fn accept( &self, conn: &Connection, ) -> Result<AdmittedMoqPeer, MoqlAdmissionError>
Run the challenge/response on conn’s first bi stream. On success,
returns the typed admitted peer; on any failure the caller MUST close
the connection (fail-closed) and serve nothing.
Sourcepub fn is_still_current(&self, admitted: &AdmittedMoqPeer) -> bool
pub fn is_still_current(&self, admitted: &AdmittedMoqPeer) -> bool
Whether a previously admitted tunnel remains bound to the same live accepted state. This deliberately re-reads the daemon-owned authority: session admission is not a permanent capability after a state advance, key rotation, expiry, or withdrawal.
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for MoqlAdmissionAuthenticator
impl !RefUnwindSafe for MoqlAdmissionAuthenticator
impl Send for MoqlAdmissionAuthenticator
impl Sync for MoqlAdmissionAuthenticator
impl Unpin for MoqlAdmissionAuthenticator
impl UnsafeUnpin for MoqlAdmissionAuthenticator
impl !UnwindSafe for MoqlAdmissionAuthenticator
Blanket Implementations§
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more