1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
use serde_big_array::big_array;
big_array! { BigArray; }
pub type SigningKey = [u8; 32];
pub type PresentationIdBytes = [u8; 32];
pub type SigningPublicKey = [u8; 96];
#[derive(Copy, Clone, Serialize, Deserialize, Debug)]
pub struct CredentialPublicKey(#[serde(with = "BigArray")] pub SigningPublicKey);
pub type ProofBytes = [u8; 48];
#[derive(Copy, Clone, Serialize, Deserialize, Debug)]
pub struct CredentialProof(#[serde(with = "BigArray")] pub ProofBytes);
pub type ProofRequestId = [u8; Nonce::BYTES];
pub type OfferId = [u8; Nonce::BYTES];
mod attribute;
mod attribute_schema;
mod attribute_type;
mod error;
mod ext;
mod fragment1;
mod fragment2;
mod offer;
mod presentation;
mod presentation_manifest;
mod request;
mod schema;
mod traits;
mod util;
pub use attribute::*;
pub use attribute_schema::*;
pub use attribute_type::*;
pub use error::*;
pub use ext::*;
pub use fragment1::*;
pub use fragment2::*;
pub use offer::*;
pub use presentation::*;
pub use presentation_manifest::*;
pub use request::*;
pub use schema::*;
use serde::{Deserialize, Serialize};
use signature_bbs_plus::Signature;
use signature_core::nonce::Nonce;
pub use traits::*;
use util::*;
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct Credential {
pub attributes: Vec<CredentialAttribute>,
pub signature: Signature,
}
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct CredentialRequestFragment(pub CredentialRequest, pub CredentialFragment1);