dchain-sdk-proto 0.9.2

Protobuf stuct defintions for Dchain
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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
// @generated
// This file is @generated by prost-build.
/// Params defines the parameters of the module.
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct Params {
    /// SudoVerifyMaxGas parameter is used for `sudoWithGasLimit` execute call for
    /// verification
    #[prost(uint64, tag = "1")]
    pub sudo_verify_max_gas: u64,
    /// SuspiciousThreshold parameter is used to determine the amount of blocks
    /// that the validator had wrong VP
    #[prost(uint64, tag = "2")]
    pub suspicious_threshold: u64,
    /// Max Presentation Length to be verified in the AVIDA verifier. NOT UPDATABLE
    /// on contract
    #[prost(uint64, tag = "3")]
    pub max_presentation_len: u64,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct GenesisState {
    /// params defines all the parameters of the module.
    #[prost(message, optional, tag = "1")]
    pub params: ::core::option::Option<Params>,
    /// SdJwtVerifierContract
    #[prost(message, repeated, tag = "2")]
    pub verifier_contracts: ::prost::alloc::vec::Vec<VerifierTypeContract>,
    /// Messages that require verification and their corresponding verification
    /// routes
    #[prost(map = "string, message", tag = "3")]
    pub x_verification_routes_registry:
        ::std::collections::HashMap<::prost::alloc::string::String, RouteAndAdditionalReq>,
    /// Init app routes
    #[prost(message, repeated, tag = "4")]
    pub init_app_routes: ::prost::alloc::vec::Vec<InitAppRoutes>,
    /// Flag that indicates is it exported state or right from the beginning
    #[prost(bool, tag = "5")]
    pub exported: bool,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct InitAppRoutes {
    #[prost(string, tag = "1")]
    pub app_addr: ::prost::alloc::string::String,
    #[prost(string, tag = "2")]
    pub app_admin: ::prost::alloc::string::String,
    #[prost(message, repeated, tag = "3")]
    pub routes: ::prost::alloc::vec::Vec<InitAppRoute>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct InitAppRoute {
    #[prost(string, tag = "1")]
    pub verifier_type: ::prost::alloc::string::String,
    #[prost(string, tag = "2")]
    pub msg_type: ::prost::alloc::string::String,
    #[prost(uint64, tag = "3")]
    pub route_id: u64,
    #[prost(message, repeated, tag = "4")]
    pub issuer_source_or_data: ::prost::alloc::vec::Vec<IssuerSourceOrData>,
    #[prost(message, repeated, tag = "5")]
    pub requirements: ::prost::alloc::vec::Vec<ReqAttr>,
    #[prost(message, repeated, tag = "6")]
    pub additional_req: ::prost::alloc::vec::Vec<ReqAttr>,
}
/// The verifier contract type to be stored in the module
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct VerifierContract {
    /// Contract ID
    #[prost(uint64, tag = "1")]
    pub code_id: u64,
    /// Contract code hash
    #[prost(bytes = "vec", tag = "2")]
    pub code_hash: ::prost::alloc::vec::Vec<u8>,
    /// The instantiated contract address with vcv auth as admin
    #[prost(string, tag = "3")]
    pub contract_address: ::prost::alloc::string::String,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Route {
    #[prost(string, tag = "1")]
    pub verifier_type: ::prost::alloc::string::String,
    #[prost(string, tag = "2")]
    pub app_addr: ::prost::alloc::string::String,
    #[prost(uint64, tag = "3")]
    pub route_id: u64,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct RouteAndAdditionalReq {
    #[prost(message, optional, tag = "1")]
    pub route: ::core::option::Option<Route>,
    #[prost(message, repeated, tag = "2")]
    pub criterion_k_vs: ::prost::alloc::vec::Vec<ReqAttr>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ReqAttr {
    #[prost(string, tag = "1")]
    pub attribute: ::prost::alloc::string::String,
    #[prost(message, optional, tag = "2")]
    pub criterion: ::core::option::Option<Criterion>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Criterion {
    #[prost(string, tag = "1")]
    pub string: ::prost::alloc::string::String,
    #[prost(message, optional, tag = "2")]
    pub number: ::core::option::Option<NumberCriterion>,
    #[prost(bool, tag = "3")]
    pub boolean: bool,
    #[prost(bool, tag = "4")]
    pub expires: bool,
    #[prost(uint64, repeated, tag = "5")]
    pub not_contained_in: ::prost::alloc::vec::Vec<u64>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct NumberCriterion {
    #[prost(uint64, tag = "1")]
    pub value: u64,
    #[prost(string, tag = "2")]
    pub operator: ::prost::alloc::string::String,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct MessageRoute {
    #[prost(string, tag = "1")]
    pub message: ::prost::alloc::string::String,
    #[prost(message, optional, tag = "2")]
    pub route: ::core::option::Option<Route>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct VerifierTypeContract {
    #[prost(string, tag = "1")]
    pub verifier_type: ::prost::alloc::string::String,
    #[prost(message, optional, tag = "2")]
    pub verifier_contract: ::core::option::Option<VerifierContract>,
}
/// CosmWasm type for instantiate
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct InitRegistration {
    #[prost(string, tag = "1")]
    pub app_addr: ::prost::alloc::string::String,
    #[prost(string, tag = "2")]
    pub app_admin: ::prost::alloc::string::String,
    #[prost(message, repeated, tag = "3")]
    pub routes: ::prost::alloc::vec::Vec<RegisterRouteRequest>,
}
/// CosmWasm type for InitRegistration
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct RegisterRouteRequest {
    #[prost(uint64, tag = "2")]
    pub route_id: u64,
    #[prost(message, optional, tag = "3")]
    pub requirements: ::core::option::Option<RouteVerificationRequirements>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct RouteVerificationRequirements {
    #[prost(message, repeated, tag = "1")]
    pub issuer_source_or_data: ::prost::alloc::vec::Vec<IssuerSourceOrData>,
    #[prost(bytes = "vec", tag = "2")]
    pub presentation_required: ::prost::alloc::vec::Vec<u8>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct OutputVerificationRequirements {
    #[prost(message, repeated, tag = "1")]
    pub presentation_required: ::prost::alloc::vec::Vec<ReqAttr>,
    #[prost(map = "string, message", tag = "2")]
    pub issuer_pubkeys: ::std::collections::HashMap<::prost::alloc::string::String, Jwk>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Jwk {
    #[prost(string, tag = "1")]
    pub kty: ::prost::alloc::string::String,
    #[prost(string, tag = "2")]
    pub crv: ::prost::alloc::string::String,
    #[prost(string, tag = "3")]
    pub x: ::prost::alloc::string::String,
    #[prost(string, tag = "4")]
    pub y: ::prost::alloc::string::String,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct IssuerSourceOrData {
    #[prost(string, tag = "1")]
    pub source: ::prost::alloc::string::String,
    #[prost(bytes = "vec", tag = "2")]
    pub data_or_location: ::prost::alloc::vec::Vec<u8>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct VerifiablePresentation {
    #[prost(bytes = "vec", tag = "1")]
    pub presentation: ::prost::alloc::vec::Vec<u8>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct UpdateRevocationListRequest {
    #[prost(uint64, tag = "1")]
    pub route_id: u64,
    #[prost(uint64, repeated, tag = "2")]
    pub revoke: ::prost::alloc::vec::Vec<u64>,
    #[prost(uint64, repeated, tag = "3")]
    pub unrevoke: ::prost::alloc::vec::Vec<u64>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct UpdateRevocationList {
    #[prost(string, tag = "1")]
    pub app_addr: ::prost::alloc::string::String,
    #[prost(message, optional, tag = "2")]
    pub request: ::core::option::Option<UpdateRevocationListRequest>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct SuspiciousValidator {
    #[prost(bytes = "vec", tag = "1")]
    pub cons_address: ::prost::alloc::vec::Vec<u8>,
    #[prost(uint64, tag = "2")]
    pub counter: u64,
    #[prost(int64, tag = "3")]
    pub power: i64,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ValidatorVoteExtension {
    /// consensus address of the validator
    #[prost(bytes = "vec", tag = "1")]
    pub cons_address: ::prost::alloc::vec::Vec<u8>,
    /// verifiable presentation of the validator
    #[prost(bytes = "vec", tag = "2")]
    pub vote_extension: ::prost::alloc::vec::Vec<u8>,
}
/// Emits when the mapping of Msg and the Route is changed.
/// The new mapping is stored is emitted
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct EventUpdateVerificationRegistry {
    #[prost(string, tag = "1")]
    pub msg_type: ::prost::alloc::string::String,
    #[prost(message, optional, tag = "2")]
    pub route: ::core::option::Option<Route>,
}
/// Emits when the verification requirements of a route is updated in the
/// relevant smart contract The new requirements is emitted
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct EventUpdatedVerificationRequirement {
    #[prost(string, tag = "1")]
    pub app_addr: ::prost::alloc::string::String,
    #[prost(uint64, tag = "2")]
    pub route_id: u64,
    #[prost(message, optional, tag = "3")]
    pub requirements: ::core::option::Option<RouteVerificationRequirements>,
}
/// Emits when a message is removed from the verification registry
/// i.e. the message no long requires verifiable presentation to be executed
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct EventRemoveMessageFromVerificationRegistry {
    #[prost(string, tag = "1")]
    pub msg_type: ::prost::alloc::string::String,
}
// ---------------------------------- RoutesRegistry
// -----------------------------------

#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct QueryRoutesRegistryRequest {}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct RoutesRegistryEntry {
    #[prost(string, tag = "1")]
    pub key: ::prost::alloc::string::String,
    #[prost(message, optional, tag = "2")]
    pub value: ::core::option::Option<RouteAndAdditionalReq>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct QueryGetRoutesRegistryResponse {
    #[prost(message, repeated, tag = "1")]
    pub routes: ::prost::alloc::vec::Vec<RoutesRegistryEntry>,
}
// ---------------------------------- MessageRoute
// -----------------------------------

#[derive(Clone, PartialEq, ::prost::Message)]
pub struct QueryMessageRouteRequest {
    #[prost(string, tag = "1")]
    pub message: ::prost::alloc::string::String,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct QueryGetMessageRouteResponse {
    #[prost(message, optional, tag = "1")]
    pub route_and_additional_req: ::core::option::Option<RouteAndAdditionalReq>,
}
// ---------------------------------- VerifierContract
// -----------------------------------

#[derive(Clone, PartialEq, ::prost::Message)]
pub struct QueryGetVerifierContractRequest {
    #[prost(string, tag = "1")]
    pub vctype: ::prost::alloc::string::String,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct QueryGetVerifierContractResponse {
    #[prost(message, optional, tag = "1")]
    pub verifier_contract: ::core::option::Option<VerifierContract>,
}
// ---------------------------------- RouteRequirements
// -----------------------------------

#[derive(Clone, PartialEq, ::prost::Message)]
pub struct QueryGetRouteRequirementsRequest {
    #[prost(string, tag = "1")]
    pub app_addr: ::prost::alloc::string::String,
    #[prost(uint64, tag = "2")]
    pub route_id: u64,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct QueryGetRouteRequirementsResponse {
    #[prost(message, optional, tag = "1")]
    pub requirements: ::core::option::Option<OutputVerificationRequirements>,
}
/// ---------------------------------- GetAuthority
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct QueryGetAuthorityRequest {}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct QueryGetAuthorityResponse {
    #[prost(string, tag = "1")]
    pub authority: ::prost::alloc::string::String,
}
/// MsgUpdateMessageInVerificationRoutesRegistry defines the
/// Msg/UpdateMessageInVerificationRoutesRegistry request type.
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct MsgUpdateMessageInVerificationRoutesRegistry {
    /// message sender (only authority allowed).
    #[prost(string, tag = "1")]
    pub sender: ::prost::alloc::string::String,
    /// type of message named proto `MessageName` in VerificationRoutesRegistry
    /// which should be updated
    #[prost(string, tag = "2")]
    pub msg_type: ::prost::alloc::string::String,
    /// defines a route for specific message in VerificationRoutesRegistry
    #[prost(message, optional, tag = "3")]
    pub route_and_additional_req: ::core::option::Option<RouteAndAdditionalReq>,
}
/// MsgUpdateRouteVerificationRequirements defines the
/// Msg/UpdateRouteVerificationRequirements request type.
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct MsgUpdateRouteVerificationRequirements {
    /// message sender (only authority allowed).
    #[prost(string, tag = "1")]
    pub sender: ::prost::alloc::string::String,
    /// defines a route for specific message in VerificationRoutesRegistry
    #[prost(message, optional, tag = "2")]
    pub route: ::core::option::Option<Route>,
    /// defines a new route verification requirements for a specific route within a
    /// smart contract
    #[prost(message, optional, tag = "3")]
    pub route_verification_requirements: ::core::option::Option<RouteVerificationRequirements>,
}
/// MsgRemoveMessageFromVerificationRoutesRegistry defines the
/// Msg/RemoveMessageFromVerificationRoutesRegistry request type.
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct MsgRemoveMessageFromVerificationRoutesRegistry {
    /// message sender (only authority allowed).
    #[prost(string, tag = "1")]
    pub sender: ::prost::alloc::string::String,
    /// message in VerificationRoutesRegistry which should be removed
    #[prost(string, tag = "2")]
    pub msg_type: ::prost::alloc::string::String,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct MsgRevokeIndexRequest {
    /// message sender (only authority allowed).
    #[prost(string, tag = "1")]
    pub sender: ::prost::alloc::string::String,
    /// Index to revoke
    #[prost(uint64, tag = "2")]
    pub index: u64,
    /// message in VerificationRoutesRegistry which index inside should be revoked
    #[prost(string, tag = "3")]
    pub type_url: ::prost::alloc::string::String,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct MsgUnrevokeIndexRequest {
    /// message sender (only authority allowed).
    #[prost(string, tag = "1")]
    pub sender: ::prost::alloc::string::String,
    /// Index to be unrevoked
    #[prost(uint64, tag = "2")]
    pub index: u64,
    /// message in VerificationRoutesRegistry which index inside should be
    /// unrevoked
    #[prost(string, tag = "3")]
    pub type_url: ::prost::alloc::string::String,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct MsgUpdateParamsRequest {
    /// message sender (only authority allowed).
    #[prost(string, tag = "1")]
    pub sender: ::prost::alloc::string::String,
    /// The new params to be set
    #[prost(message, optional, tag = "2")]
    pub params: ::core::option::Option<Params>,
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct MsgUpdateParamsResponse {
    #[prost(message, optional, tag = "1")]
    pub params: ::core::option::Option<Params>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct MsgExtendedProposalTxn {
    /// The proposal's VP
    #[prost(bytes = "vec", tag = "1")]
    pub vp: ::prost::alloc::vec::Vec<u8>,
    /// List of all vote extensions from validators
    #[prost(message, repeated, tag = "2")]
    pub vote_extensions: ::prost::alloc::vec::Vec<ValidatorVoteExtension>,
    /// List of suspected validators. This is a list of validators that are
    /// suspected of being with incorrect VP or providing empty VoteExtension on
    /// purpose.
    #[prost(message, repeated, tag = "3")]
    pub suspicious_validators: ::prost::alloc::vec::Vec<SuspiciousValidator>,
}
/// MsgUpdateMessageInVerificationRoutesRegistryResponse defines the
/// Msg/UpdateMessageInVerificationRoutesRegistry response type.
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct MsgUpdateMessageInVerificationRoutesRegistryResponse {}
/// MsgRemoveMessageFromVerificationRoutesRegistryResponse defines the
/// Msg/RemoveMessageFromVerificationRoutesRegistry response type.
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct MsgRemoveMessageFromVerificationRoutesRegistryResponse {}
/// MsgUpdateRouteVerificationRequirementsResponse  defines the
/// Msg/UpdateRouteVerificationRequirements response type.
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct MsgUpdateRouteVerificationRequirementsResponse {}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct MsgRevokeIndexResponse {
    #[prost(message, optional, tag = "1")]
    pub requirements: ::core::option::Option<OutputVerificationRequirements>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct MsgUnrevokeIndexResponse {
    #[prost(message, optional, tag = "1")]
    pub requirements: ::core::option::Option<OutputVerificationRequirements>,
}
include!("d.vcv.v1.tonic.rs");
// @@protoc_insertion_point(module)