pub struct MoqAuthzConfig {
pub authorizer: Option<SharedSubscribeAuthorizer>,
pub tenant_resolver: Option<PeerTenantResolver>,
pub ingress_authorizer: Option<SharedIngressAuthorizer>,
pub admission: Option<Arc<MoqlAdmissionAuthenticator>>,
}Expand description
#276 authorization config for a moq accept path: an optional subscribe authorizer and an optional peer→tenant resolver for per-tenant announce scoping. Absence of fresh application/session proof is always fail-closed; these hooks cannot turn an anonymous carrier into an authenticated peer.
#1027: installing an MoqlAdmissionAuthenticator changes the posture —
the accept path runs the inside-carrier Ed25519 + ML-DSA-65
challenge/response before any moq machinery and serves only the admitted
peer’s tenant scope. Without it, the anonymous fail-closed refusal below is
unchanged.
Fields§
Subscribe-time authorization hook (public-open / private-gated).
tenant_resolver: Option<PeerTenantResolver>Maps a peer identity to its tenant for per-tenant announce scoping.
Explicit trusted producer/relay decision. Its absence is a deliberate deny: an admitted peer is a read-only subscriber, never a publisher.
admission: Option<Arc<MoqlAdmissionAuthenticator>>#1027 inside-carrier admission authenticator. When set, every accepted
moql connection must prove an accepted current Ed25519 + ML-DSA-65
identity before the moq handshake; the carrier NodeId alone is refused.
Implementations§
Source§impl MoqAuthzConfig
impl MoqAuthzConfig
Sourcepub fn tenant_for(&self, peer: &PeerIdentity) -> Option<String>
pub fn tenant_for(&self, peer: &PeerIdentity) -> Option<String>
Resolve the tenant for peer, if a resolver is configured.
Set/replace the subscribe authorizer.
Install the service-owned trusted ingress decision. This hook is kept separate from tenant admission: a subject→tenant row is not a producer role grant.
Install an optional service-owned ingress decision without converting an absent deployment policy into a grant.
Whether the admitted peer has an explicit trusted ingress grant. Missing configuration fails closed to read-only delivery.
Sourcepub fn with_admission(self, admission: Arc<MoqlAdmissionAuthenticator>) -> Self
pub fn with_admission(self, admission: Arc<MoqlAdmissionAuthenticator>) -> Self
Install the #1027 inside-carrier admission authenticator. The
authenticator carries its own authoritative subject→tenant resolver;
tenant_resolver is only consulted for peers authenticated by other
means (none today on this path).
Gate an MoQ session while the transport cannot surface track names.
Dormant (None) preserves the legacy pass-through. Once an authorizer
is installed, its coarse admission decision is mandatory; current
implementations deny until moq-net’s #276 per-track callback exists.
Trait Implementations§
Source§impl Clone for MoqAuthzConfig
impl Clone for MoqAuthzConfig
Source§fn clone(&self) -> MoqAuthzConfig
fn clone(&self) -> MoqAuthzConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Default for MoqAuthzConfig
impl Default for MoqAuthzConfig
Source§fn default() -> MoqAuthzConfig
fn default() -> MoqAuthzConfig
Auto Trait Implementations§
impl Freeze for MoqAuthzConfig
impl !RefUnwindSafe for MoqAuthzConfig
impl Send for MoqAuthzConfig
impl Sync for MoqAuthzConfig
impl Unpin for MoqAuthzConfig
impl UnsafeUnpin for MoqAuthzConfig
impl !UnwindSafe for MoqAuthzConfig
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§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