pub enum CredentialSubcommand {
Issue {
issuer: String,
to: String,
cap: Vec<Capability>,
role: Option<String>,
expires_in: Option<i64>,
},
Revoke {
credential_said: String,
issuer: String,
},
List {
issuer: Option<String>,
include_revoked: bool,
},
Verify {
credential_said: String,
issuer: String,
require_witnesses: bool,
usage_counter: Option<PathBuf>,
},
Present {
subject: String,
said: String,
audience: String,
nonce: String,
with_evidence: bool,
},
}Expand description
Credential subcommands.
Variants§
Issue
Issue a capability credential to an issuee (its KEL must already exist).
Fields
cap: Vec<Capability>Capability to grant (repeatable).
Revoke
Revoke a credential (anchors a rev in the issuer’s KEL). Idempotent.
Fields
List
List the issuer’s live credentials (issued − revoked).
Fields
Verify
Verify a credential, resolving the issuer KEL/TEL + witness receipts.
Fields
usage_counter: Option<PathBuf>Enforce a quantitative usage cap against an observed call count.
Path to a JSON usage observation {"said":"…","calls_used":N}. When the
credential carries a calls:<N> cap, the observed count is checked
against the verifier’s monotonic usage ledger: an over-budget count fails
with cap_exceeded, a replayed (lower) count fails with
usage_counter_rolled_back. Omitted for credentials without a usage cap.
Present
Present a credential: prove control of the subject AID and emit an Auths-Presentation header.
Fields
Trait Implementations§
Source§impl Clone for CredentialSubcommand
impl Clone for CredentialSubcommand
Source§fn clone(&self) -> CredentialSubcommand
fn clone(&self) -> CredentialSubcommand
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 CredentialSubcommand
impl Debug for CredentialSubcommand
Source§impl FromArgMatches for CredentialSubcommand
impl FromArgMatches for CredentialSubcommand
Source§fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
Source§fn from_arg_matches_mut(
__clap_arg_matches: &mut ArgMatches,
) -> Result<Self, Error>
fn from_arg_matches_mut( __clap_arg_matches: &mut ArgMatches, ) -> Result<Self, Error>
Source§fn update_from_arg_matches(
&mut self,
__clap_arg_matches: &ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches( &mut self, __clap_arg_matches: &ArgMatches, ) -> Result<(), Error>
ArgMatches to self.Source§fn update_from_arg_matches_mut<'b>(
&mut self,
__clap_arg_matches: &mut ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches_mut<'b>( &mut self, __clap_arg_matches: &mut ArgMatches, ) -> Result<(), Error>
ArgMatches to self.Source§impl Subcommand for CredentialSubcommand
impl Subcommand for CredentialSubcommand
Source§fn augment_subcommands<'b>(__clap_app: Command) -> Command
fn augment_subcommands<'b>(__clap_app: Command) -> Command
Source§fn augment_subcommands_for_update<'b>(__clap_app: Command) -> Command
fn augment_subcommands_for_update<'b>(__clap_app: Command) -> Command
Command so it can instantiate self via
FromArgMatches::update_from_arg_matches_mut Read moreSource§fn has_subcommand(__clap_name: &str) -> bool
fn has_subcommand(__clap_name: &str) -> bool
Self can parse a specific subcommand