pb

package
v0.52.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 14, 2026 License: MIT Imports: 6 Imported by: 9 modules, 7 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_core_record_pb_envelope_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type Envelope

type Envelope struct {

	// public_key is the public key of the keypair the enclosed payload was
	// signed with.
	PublicKey *pb.PublicKey `protobuf:"bytes,1,opt,name=public_key,json=publicKey,proto3" json:"public_key,omitempty"`
	// payload_type encodes the type of payload, so that it can be deserialized
	// deterministically.
	PayloadType []byte `protobuf:"bytes,2,opt,name=payload_type,json=payloadType,proto3" json:"payload_type,omitempty"`
	// payload is the actual payload carried inside this envelope.
	Payload []byte `protobuf:"bytes,3,opt,name=payload,proto3" json:"payload,omitempty"`
	// signature is the signature produced by the private key corresponding to
	// the enclosed public key, over the payload, prefixing a domain string for
	// additional security.
	Signature []byte `protobuf:"bytes,5,opt,name=signature,proto3" json:"signature,omitempty"`
	// contains filtered or unexported fields
}

Envelope encloses a signed payload produced by a peer, along with the public key of the keypair it was signed with so that it can be statelessly validated by the receiver.

The payload is prefixed with a byte string that determines the type, so it can be deserialized deterministically. Often, this byte string is a multicodec.

func (*Envelope) Descriptor deprecated

func (*Envelope) Descriptor() ([]byte, []int)

Deprecated: Use Envelope.ProtoReflect.Descriptor instead.

func (*Envelope) GetPayload

func (x *Envelope) GetPayload() []byte

func (*Envelope) GetPayloadType

func (x *Envelope) GetPayloadType() []byte

func (*Envelope) GetPublicKey

func (x *Envelope) GetPublicKey() *pb.PublicKey

func (*Envelope) GetSignature

func (x *Envelope) GetSignature() []byte

func (*Envelope) ProtoMessage

func (*Envelope) ProtoMessage()

func (*Envelope) ProtoReflect added in v0.25.0

func (x *Envelope) ProtoReflect() protoreflect.Message

func (*Envelope) Reset

func (x *Envelope) Reset()

func (*Envelope) String

func (x *Envelope) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL