Documentation
¶
Index ¶
- Variables
- type MerkleProof
- type PropellerUnit
- func (*PropellerUnit) Descriptor() ([]byte, []int)deprecated
- func (x *PropellerUnit) GetCommitteeId() *common.Hash256
- func (x *PropellerUnit) GetIndex() uint64
- func (x *PropellerUnit) GetMerkleProof() *MerkleProof
- func (x *PropellerUnit) GetMerkleRoot() *common.Hash256
- func (x *PropellerUnit) GetNonce() uint64
- func (x *PropellerUnit) GetPublisher() *common.PeerID
- func (x *PropellerUnit) GetShards() *ShardsOfPeer
- func (x *PropellerUnit) GetSignature() []byte
- func (*PropellerUnit) ProtoMessage()
- func (x *PropellerUnit) ProtoReflect() protoreflect.Message
- func (x *PropellerUnit) Reset()
- func (x *PropellerUnit) String() string
- type PropellerUnitBatch
- func (*PropellerUnitBatch) Descriptor() ([]byte, []int)deprecated
- func (x *PropellerUnitBatch) GetBatch() []*PropellerUnit
- func (*PropellerUnitBatch) ProtoMessage()
- func (x *PropellerUnitBatch) ProtoReflect() protoreflect.Message
- func (x *PropellerUnitBatch) Reset()
- func (x *PropellerUnitBatch) String() string
- type Shard
- type ShardsOfPeer
Constants ¶
This section is empty.
Variables ¶
var File_consensus_propeller_proto_propeller_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type MerkleProof ¶
type MerkleProof struct {
// The sibling hashes needed to reconstruct the path from the leaf to the root.
// Each hash is 32 bytes.
Siblings []*common.Hash256 `protobuf:"bytes,1,rep,name=siblings,proto3" json:"siblings,omitempty"`
// contains filtered or unexported fields
}
A Merkle proof consisting of sibling hashes used to verify that a leaf belongs to a Merkle tree. Each sibling hash is 32 bytes (SHA-256). The siblings are ordered from leaf level to root level.
func (*MerkleProof) Descriptor
deprecated
func (*MerkleProof) Descriptor() ([]byte, []int)
Deprecated: Use MerkleProof.ProtoReflect.Descriptor instead.
func (*MerkleProof) GetSiblings ¶
func (x *MerkleProof) GetSiblings() []*common.Hash256
func (*MerkleProof) ProtoMessage ¶
func (*MerkleProof) ProtoMessage()
func (*MerkleProof) ProtoReflect ¶
func (x *MerkleProof) ProtoReflect() protoreflect.Message
func (*MerkleProof) Reset ¶
func (x *MerkleProof) Reset()
func (*MerkleProof) String ¶
func (x *MerkleProof) String() string
type PropellerUnit ¶
type PropellerUnit struct {
// The shards assigned to this unit's peer.
Shards *ShardsOfPeer `protobuf:"bytes,1,opt,name=shards,proto3" json:"shards,omitempty"`
// The position of this shard in the erasure coding scheme.
Index uint64 `protobuf:"varint,2,opt,name=index,proto3" json:"index,omitempty"`
// The Merkle root of all shards, used to verify shard integrity.
MerkleRoot *common.Hash256 `protobuf:"bytes,3,opt,name=merkle_root,json=merkleRoot,proto3" json:"merkle_root,omitempty"`
// The Merkle proof that this shard belongs to the tree with the given root.
MerkleProof *MerkleProof `protobuf:"bytes,4,opt,name=merkle_proof,json=merkleProof,proto3" json:"merkle_proof,omitempty"`
// The peer ID of the original publisher who created and signed this unit.
Publisher *common.PeerID `protobuf:"bytes,5,opt,name=publisher,proto3" json:"publisher,omitempty"`
// Cryptographic signature from the publisher over the merkle_root.
Signature []byte `protobuf:"bytes,6,opt,name=signature,proto3" json:"signature,omitempty"`
// Committee identifier for multiplexing different message streams.
CommitteeId *common.Hash256 `protobuf:"bytes,7,opt,name=committee_id,json=committeeId,proto3" json:"committee_id,omitempty"`
// A strictly increasing number, to avoid replays.
// Current implementation is nanoseconds since UNIX_EPOCH.
// TODO(guyn): CRITICAL: protect against replay attacks using this timestamp
Nonce uint64 `protobuf:"varint,8,opt,name=nonce,proto3" json:"nonce,omitempty"`
// contains filtered or unexported fields
}
A single unit in the Propeller protocol containing shards of erasure-coded data along with cryptographic proofs for verification.
func (*PropellerUnit) Descriptor
deprecated
func (*PropellerUnit) Descriptor() ([]byte, []int)
Deprecated: Use PropellerUnit.ProtoReflect.Descriptor instead.
func (*PropellerUnit) GetCommitteeId ¶
func (x *PropellerUnit) GetCommitteeId() *common.Hash256
func (*PropellerUnit) GetIndex ¶
func (x *PropellerUnit) GetIndex() uint64
func (*PropellerUnit) GetMerkleProof ¶
func (x *PropellerUnit) GetMerkleProof() *MerkleProof
func (*PropellerUnit) GetMerkleRoot ¶
func (x *PropellerUnit) GetMerkleRoot() *common.Hash256
func (*PropellerUnit) GetNonce ¶
func (x *PropellerUnit) GetNonce() uint64
func (*PropellerUnit) GetPublisher ¶
func (x *PropellerUnit) GetPublisher() *common.PeerID
func (*PropellerUnit) GetShards ¶
func (x *PropellerUnit) GetShards() *ShardsOfPeer
func (*PropellerUnit) GetSignature ¶
func (x *PropellerUnit) GetSignature() []byte
func (*PropellerUnit) ProtoMessage ¶
func (*PropellerUnit) ProtoMessage()
func (*PropellerUnit) ProtoReflect ¶
func (x *PropellerUnit) ProtoReflect() protoreflect.Message
func (*PropellerUnit) Reset ¶
func (x *PropellerUnit) Reset()
func (*PropellerUnit) String ¶
func (x *PropellerUnit) String() string
type PropellerUnitBatch ¶
type PropellerUnitBatch struct {
Batch []*PropellerUnit `protobuf:"bytes,1,rep,name=batch,proto3" json:"batch,omitempty"`
// contains filtered or unexported fields
}
A batch of PropellerUnits for efficient transmission.
func (*PropellerUnitBatch) Descriptor
deprecated
func (*PropellerUnitBatch) Descriptor() ([]byte, []int)
Deprecated: Use PropellerUnitBatch.ProtoReflect.Descriptor instead.
func (*PropellerUnitBatch) GetBatch ¶
func (x *PropellerUnitBatch) GetBatch() []*PropellerUnit
func (*PropellerUnitBatch) ProtoMessage ¶
func (*PropellerUnitBatch) ProtoMessage()
func (*PropellerUnitBatch) ProtoReflect ¶
func (x *PropellerUnitBatch) ProtoReflect() protoreflect.Message
func (*PropellerUnitBatch) Reset ¶
func (x *PropellerUnitBatch) Reset()
func (*PropellerUnitBatch) String ¶
func (x *PropellerUnitBatch) String() string
type Shard ¶
type Shard struct {
Data []byte `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"`
// contains filtered or unexported fields
}
A single erasure-coded fragment of the original message.
func (*Shard) Descriptor
deprecated
func (*Shard) ProtoMessage ¶
func (*Shard) ProtoMessage()
func (*Shard) ProtoReflect ¶
func (x *Shard) ProtoReflect() protoreflect.Message
type ShardsOfPeer ¶
type ShardsOfPeer struct {
Shards []*Shard `protobuf:"bytes,1,rep,name=shards,proto3" json:"shards,omitempty"`
// contains filtered or unexported fields
}
A collection of shards assigned to a single peer. The proto-encoded bytes of this message are used as Merkle tree leaf data, ensuring cross-language determinism.
func (*ShardsOfPeer) Descriptor
deprecated
func (*ShardsOfPeer) Descriptor() ([]byte, []int)
Deprecated: Use ShardsOfPeer.ProtoReflect.Descriptor instead.
func (*ShardsOfPeer) GetShards ¶
func (x *ShardsOfPeer) GetShards() []*Shard
func (*ShardsOfPeer) ProtoMessage ¶
func (*ShardsOfPeer) ProtoMessage()
func (*ShardsOfPeer) ProtoReflect ¶
func (x *ShardsOfPeer) ProtoReflect() protoreflect.Message
func (*ShardsOfPeer) Reset ¶
func (x *ShardsOfPeer) Reset()
func (*ShardsOfPeer) String ¶
func (x *ShardsOfPeer) String() string