src/principal.rs

RuView · v2/crates/ruview-auth/src/principal.rs · rust · MIT
auth

Represents an authenticated caller with scopes for authorization checks.

// Source: https://github.com/ruvnet/RuView | License: MIT | Copyright 2024 rUv
// Provided via justclaw.it.com; keep this notice with the code.
//! The authenticated caller, and the scopes it consented to.

use std::collections::BTreeSet;

/// RuView's own scopes, registered on the `ruview` OAuth client
/// (identity migration `0016`, ADR-060).
///
/// Split by **blast radius**, not by endpoint count: the question is whether a
/// leaked token can destroy something, not how many routes it covers.
pub mod scope {
    /// Observe: sensing/pose streams, one-shot inference, reading metadata.
    ///
    /// Not "harmless" — for a presence and vital-signs sensor, read access tells
    /// the holder who is home. It is *non-destructive*, which is a weaker claim.
    pub const SENSING_READ: &str

... (truncated -- full source via MCP)

See the full source, get the GitHub permalink, and search for more like it.

Get a free API key