pub enum Cred {
Public,
Login,
Agent,
Human,
AnyHuman,
Bootstrap,
Read,
Any,
}Expand description
What a request must carry before its method runs. Deny by default: a
method not in METHODS does not exist.
Variants§
Public
Nothing.
Login
A presence signature inside the request (human.login).
Agent
An agent session token; the repository is the token’s.
Human
A human session whose key is enrolled in the request’s repository.
AnyHuman
A human session whose key is enrolled in at least one repository.
Bootstrap
AnyHuman, or nothing while the daemon serves no repository yet
(the first lonca init or lonca restore): there is no key to
check against, and the socket is the only guard, as it was.
Read
Agent (for the token’s repository) or Human.
Any
Any live token, agent or human.
Implementations§
Trait Implementations§
impl Copy for Cred
impl Eq for Cred
impl StructuralPartialEq for Cred
Auto Trait Implementations§
impl Forget for Cred
impl Freeze for Cred
impl RefUnwindSafe for Cred
impl Send for Cred
impl Sync for Cred
impl Unpin for Cred
impl UnsafeUnpin for Cred
impl UnwindSafe for Cred
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.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> ⓘ
Converts
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> ⓘ
Converts
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