pub struct ZkProofInputs {
pub credential_id: CredentialId,
pub issuer_public_key: [u8; 32],
pub issuer_key_id: String,
pub content_commitment: [u8; 32],
pub subject_commitment: [u8; 32],
pub jurisdiction: String,
pub eligibility_type: Option<EligibilityType>,
pub valid_from: Timestamp,
pub expires_at: Timestamp,
pub revocation_merkle_root: Option<[u8; 32]>,
pub current_block_height: BlockHeight,
pub issuer_signature: [u8; 64],
}Expand description
Data structure for ZK proof inputs. This defines what fields future ZK circuits will consume to prove eligibility without revealing identity.
Fields§
§credential_id: CredentialIdCredential ID being proven
issuer_public_key: [u8; 32]Issuer’s public key used for signing
issuer_key_id: StringIssuer key ID (for key rotation support)
content_commitment: [u8; 32]Content commitment
subject_commitment: [u8; 32]Subject commitment
jurisdiction: StringJurisdiction code
eligibility_type: Option<EligibilityType>Eligibility type (for 802 credentials)
valid_from: TimestampValid from timestamp
expires_at: TimestampExpiry timestamp
revocation_merkle_root: Option<[u8; 32]>Revocation check hook (merkle root or on-chain state root)
current_block_height: BlockHeightCurrent block height (for freshness)
issuer_signature: [u8; 64]Issuer signature
Trait Implementations§
Source§impl Clone for ZkProofInputs
impl Clone for ZkProofInputs
Source§fn clone(&self) -> ZkProofInputs
fn clone(&self) -> ZkProofInputs
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ZkProofInputs
impl Debug for ZkProofInputs
Source§impl<'de> Deserialize<'de> for ZkProofInputs
impl<'de> Deserialize<'de> for ZkProofInputs
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for ZkProofInputs
impl PartialEq for ZkProofInputs
Source§fn eq(&self, other: &ZkProofInputs) -> bool
fn eq(&self, other: &ZkProofInputs) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for ZkProofInputs
impl Serialize for ZkProofInputs
impl Eq for ZkProofInputs
impl StructuralPartialEq for ZkProofInputs
Auto Trait Implementations§
impl Freeze for ZkProofInputs
impl RefUnwindSafe for ZkProofInputs
impl Send for ZkProofInputs
impl Sync for ZkProofInputs
impl Unpin for ZkProofInputs
impl UnsafeUnpin for ZkProofInputs
impl UnwindSafe for ZkProofInputs
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