macaroonpb

package module
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Mar 8, 2021 License: LGPL-3.0 Imports: 5 Imported by: 2

README

Macaroon ID Protocol Buffers

This module defines the serialization format of macaroon identifiers for macaroons created by the macaroon-bakery. For the most part this encoding is considered an internal implementation detail of the macaroon-bakery and external applications should not rely on any of the details of this encoding being maintained between different bakery versions.

This is broken out into a separate module as the protobuf implementation works in such a way that one cannot have multiple definitions of a message in any particular application's dependency tree. This module therefore provides a common definition for use by multiple versions of the macaroon-bakery to facilitate easier migration in client applications.

Documentation

Overview

Package macaroonpb defines the serialization details of macaroon ids used in the macaroon-bakery.

Index

Constants

This section is empty.

Variables

Functions

This section is empty.

Types

type MacaroonId

type MacaroonId struct {
	Nonce     []byte `protobuf:"bytes,1,opt,name=nonce,proto3" json:"nonce,omitempty"`
	StorageId []byte `protobuf:"bytes,2,opt,name=storageId,proto3" json:"storageId,omitempty"`
	Ops       []*Op  `protobuf:"bytes,3,rep,name=ops,proto3" json:"ops,omitempty"`
	// contains filtered or unexported fields
}

func (*MacaroonId) Descriptor deprecated

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

Deprecated: Use MacaroonId.ProtoReflect.Descriptor instead.

func (*MacaroonId) GetNonce

func (x *MacaroonId) GetNonce() []byte

func (*MacaroonId) GetOps

func (x *MacaroonId) GetOps() []*Op

func (*MacaroonId) GetStorageId

func (x *MacaroonId) GetStorageId() []byte

func (*MacaroonId) MarshalBinary

func (id *MacaroonId) MarshalBinary() ([]byte, error)

MarshalBinary implements encoding.BinaryMarshal.

func (*MacaroonId) ProtoMessage

func (*MacaroonId) ProtoMessage()

func (*MacaroonId) ProtoReflect

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

func (*MacaroonId) Reset

func (x *MacaroonId) Reset()

func (*MacaroonId) String

func (x *MacaroonId) String() string

func (*MacaroonId) UnmarshalBinary

func (id *MacaroonId) UnmarshalBinary(data []byte) error

UnmarshalBinary implements encoding.UnmarshalBinary.

type Op

type Op struct {
	Entity  string   `protobuf:"bytes,1,opt,name=entity,proto3" json:"entity,omitempty"`
	Actions []string `protobuf:"bytes,2,rep,name=actions,proto3" json:"actions,omitempty"`
	// contains filtered or unexported fields
}

func (*Op) Descriptor deprecated

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

Deprecated: Use Op.ProtoReflect.Descriptor instead.

func (*Op) GetActions

func (x *Op) GetActions() []string

func (*Op) GetEntity

func (x *Op) GetEntity() string

func (*Op) ProtoMessage

func (*Op) ProtoMessage()

func (*Op) ProtoReflect

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

func (*Op) Reset

func (x *Op) Reset()

func (*Op) String

func (x *Op) String() string

Jump to

Keyboard shortcuts

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