pub struct BootstrapCasAuthorizer { /* private fields */ }Expand description
Enforcing authorizer for the live GET /get_xorb/{hash}/ surface (#1094):
an explicit bootstrap grant list, default-deny, one audit event per decision.
This is plane #1 of #1091’s R4b compile-and-ratchet MAC rollout: the route
flips to enforcing on day one behind AUTHENTICATED_XORB_READ, making
today’s implicit authenticated floor an explicit, auditable policy object
instead of a silent AllowAllCasAuthorizer.
§Ratchet path (grant breadth → 0)
The day-one grant is maximally broad on two axes: every authenticated subject, every xorb address. Ratcheting is a deliberate, reviewable edit of the grant list, sequenced with the MAC-activation prerequisites:
- #699 lands provenance labels — repo/compartment
security_labels on xorb-bearing manifests (carrier-(b)) give each request a real object label. Grants can then narrow per-domain, then per-compartment. - #698 flows subject clearances — authority-owned
Claims.clearancegives the caller a realSecurityContext;CasGrantSubjectgains clearance-bearing variants and the decision becomes dominance (subject.ctx ⊒ object.label) per op. - Breadth 0 — with labels + clearances live, the grant list empties
(==
DenyAllCasAuthorizer) and this type is retired in favor of the MAC authorizer on the sameCasMountAuthorizerseam.
That labeling/clearance work is not in scope here; only the seam and the day-one grant are.
Audit: allows log at debug, denies at warn (denials are
security-relevant). Tamper-evident decision audit (#573,
crate::mac::audit) takes over when the MAC authorizer lands.
Implementations§
Source§impl BootstrapCasAuthorizer
impl BootstrapCasAuthorizer
Sourcepub fn new() -> Self
pub fn new() -> Self
The day-one policy (#1094): exactly AUTHENTICATED_XORB_READ.
Sourcepub fn with_grants(grants: Vec<CasMountGrant>) -> Self
pub fn with_grants(grants: Vec<CasMountGrant>) -> Self
An explicit grant list — the ratchet knob. Narrow the list as #699
labels and #698 clearances land; an empty list denies everything
(equivalent to DenyAllCasAuthorizer).
Trait Implementations§
Source§impl Clone for BootstrapCasAuthorizer
impl Clone for BootstrapCasAuthorizer
Source§fn clone(&self) -> BootstrapCasAuthorizer
fn clone(&self) -> BootstrapCasAuthorizer
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for BootstrapCasAuthorizer
impl Debug for BootstrapCasAuthorizer
Auto Trait Implementations§
impl Freeze for BootstrapCasAuthorizer
impl RefUnwindSafe for BootstrapCasAuthorizer
impl Send for BootstrapCasAuthorizer
impl Sync for BootstrapCasAuthorizer
impl Unpin for BootstrapCasAuthorizer
impl UnsafeUnpin for BootstrapCasAuthorizer
impl UnwindSafe for BootstrapCasAuthorizer
Blanket Implementations§
§impl<T> AnySync for T
impl<T> AnySync for T
§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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
§impl<T> Identity for Twhere
T: ?Sized,
impl<T> Identity for Twhere
T: ?Sized,
§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 moreSource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request