pub struct CredentialSubjectMembership {
pub id: String,
pub digest_multibase: Option<String>,
}Expand description
Membership Credential subject
The two directions of a membership edge share this shape and are told apart by
digest: a community-issued VMC (the membership grant) MUST omit it, and a
member-issued VMC (the membership acknowledgement) MUST carry it. Where both endpoints
are community identifiers, as in VTN membership, digestMultibase is the only
discriminator — the issuer and subject rules cannot separate the directions.
Fields§
§id: String§digest_multibase: Option<String>Digest of the community-issued VMC this acknowledges, as DTGCredential::digest_multibase computes it.
REQUIRED on the member-issued VMC, and MUST be omitted on the community-issued VMC.
Option rather than two structs because the same property distinguishes the two
directions: a type that could not represent both could not deserialize the pair.
Serializes as digestMultibase. The Working Draft 01 name digest is accepted on
the wire so that credentials issued against that draft still parse; the value
encoding also changed, so such a credential parses and then fails to compare, with
DTGCredentialError::InvalidDigest rather than a silent mismatch.
Trait Implementations§
Source§impl Clone for CredentialSubjectMembership
impl Clone for CredentialSubjectMembership
Source§fn clone(&self) -> CredentialSubjectMembership
fn clone(&self) -> CredentialSubjectMembership
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more