-
Notifications
You must be signed in to change notification settings - Fork 2
/
ethereum.proto
131 lines (111 loc) · 3.24 KB
/
ethereum.proto
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
syntax = "proto3";
package ibc.lightclients.ethereum.v1;
option go_package = "github.com/datachainlab/ethereum-lcp/go/light-clients/ethereum/types";
import "ibc/core/client/v1/client.proto";
import "google/protobuf/timestamp.proto";
import "google/protobuf/duration.proto";
message ClientState {
bytes genesis_validators_root = 1;
uint64 min_sync_committee_participants = 2;
uint64 genesis_time = 3;
ForkParameters fork_parameters = 4;
uint64 seconds_per_slot = 5;
uint64 slots_per_epoch = 6;
uint64 epochs_per_sync_committee_period = 7;
bytes ibc_address = 8;
bytes ibc_commitments_slot = 9;
Fraction trust_level = 10;
google.protobuf.Duration trusting_period = 11;
google.protobuf.Duration max_clock_drift = 12;
uint64 latest_execution_block_number = 13;
ibc.core.client.v1.Height frozen_height = 14;
}
message ConsensusState {
uint64 slot = 1;
bytes storage_root = 2;
google.protobuf.Timestamp timestamp = 3;
bytes current_sync_committee = 4;
bytes next_sync_committee = 5;
}
message Header {
TrustedSyncCommittee trusted_sync_committee = 1;
ConsensusUpdate consensus_update = 2;
ExecutionUpdate execution_update = 3;
AccountUpdate account_update = 4;
// seconds from unix epoch
uint64 timestamp = 5;
}
message TrustedSyncCommittee {
ibc.core.client.v1.Height trusted_height = 1;
SyncCommittee sync_committee = 2;
bool is_next = 3;
}
message ForkParameters {
bytes genesis_fork_version = 1;
repeated Fork forks = 2;
}
message Fraction {
uint64 numerator = 1;
uint64 denominator = 2;
}
message Fork {
bytes version = 1;
uint64 epoch = 2;
ForkSpec spec = 3;
}
message ForkSpec {
uint32 finalized_root_gindex = 1;
uint32 current_sync_committee_gindex = 2;
uint32 next_sync_committee_gindex = 3;
uint32 execution_payload_gindex = 4;
uint32 execution_payload_state_root_gindex = 5;
uint32 execution_payload_block_number_gindex = 6;
}
message ConsensusUpdate {
BeaconBlockHeader attested_header = 1;
SyncCommittee next_sync_committee = 2;
repeated bytes next_sync_committee_branch = 3;
BeaconBlockHeader finalized_header = 4;
repeated bytes finalized_header_branch = 5;
bytes finalized_execution_root = 6;
repeated bytes finalized_execution_branch = 7;
SyncAggregate sync_aggregate = 8;
uint64 signature_slot = 9;
}
message SyncCommittee {
repeated bytes pubkeys = 1;
bytes aggregate_pubkey = 2;
}
message SyncAggregate {
bytes sync_committee_bits = 1;
bytes sync_committee_signature = 2;
}
message ExecutionUpdate {
bytes state_root = 1;
repeated bytes state_root_branch = 2;
uint64 block_number = 3;
repeated bytes block_number_branch = 4;
}
message AccountUpdate {
bytes account_proof = 1;
bytes account_storage_root = 2;
}
message BeaconBlockHeader {
uint64 slot = 1;
uint64 proposer_index = 2;
bytes parent_root = 3;
bytes state_root = 4;
bytes body_root = 5;
}
message FinalizedHeaderMisbehaviour {
string client_id = 1;
TrustedSyncCommittee trusted_sync_committee = 2;
ConsensusUpdate consensus_update_1 = 3;
ConsensusUpdate consensus_update_2 = 4;
}
message NextSyncCommitteeMisbehaviour {
string client_id = 1;
TrustedSyncCommittee trusted_sync_committee = 2;
ConsensusUpdate consensus_update_1 = 3;
ConsensusUpdate consensus_update_2 = 4;
}