Crate penumbra_proto

Source
Expand description

Protobuf definitions for Penumbra.

This crate only contains the .proto files and the Rust types generated from them. These types only handle parsing the wire format; validation should be performed by converting them into an appropriate domain type, as in the following diagram:

┌───────┐          ┌──────────────┐               ┌──────────────┐
│encoded│ protobuf │penumbra_proto│ TryFrom/Into  │ domain types │
│ bytes │<──wire ─>│    types     │<─validation ─>│(other crates)│
└───────┘  format  └──────────────┘   boundary    └──────────────┘

The DomainType marker trait can be implemented on a domain type to ensure these conversions exist.

Re-exports§

pub use state::StateReadProto;cnidarium
pub use state::StateWriteProto;cnidarium
pub use penumbra::*;

Modules§

box_grpc_svcbox-grpc
cosmos
event
Helper trait for using Protobuf messages as ABCI events.
noble
penumbra
serializers
Helper methods used for shaping the JSON (and other Serde) formats derived from the protos. TODO: Extract the Bech32 prefixes into a module at the root of the crate, and then remove this module entirely. We don’t want to be custom-shaping serde formats, we want to have those match protobuf JSON exactly.
statecnidarium
tendermint

Constants§

FILE_DESCRIPTOR_SETrpc

Traits§

DomainType
A marker type that captures the relationships between a domain type (Self) and a protobuf type (Self::Proto).
Message
A Protocol Buffers message.
Name
Associate a type name with a Message type.

Derive Macros§

Message