reference

package
v4.0.0 Latest Latest
Warning

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

Go to latest
Published: May 23, 2019 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Ref

type Ref struct {
	Address              []byte   `protobuf:"bytes,1,opt,name=Address,proto3" json:"Address,omitempty"`
	SecretKey            []byte   `protobuf:"bytes,2,opt,name=SecretKey,proto3" json:"SecretKey,omitempty"`
	Salt                 []byte   `protobuf:"bytes,3,opt,name=Salt,proto3" json:"Salt,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func FromPlaintext

func FromPlaintext(plaintext string) *Ref

func New

func New(address, secretKey, salt []byte) *Ref

func (*Ref) Descriptor

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

func (*Ref) GetAddress

func (m *Ref) GetAddress() []byte

func (*Ref) GetSalt

func (m *Ref) GetSalt() []byte

func (*Ref) GetSecretKey

func (m *Ref) GetSecretKey() []byte

func (*Ref) Plaintext

func (ref *Ref) Plaintext(nonce []byte) string

Obtain the canonical plaintext for the Ref with an optional nonce that can be be used to salt the plaintext in order to obtain an unpredictable version of the plaintext for encryption purposes (i.e. for Grants). The nonce is discarded when read by FromPlaintext

func (*Ref) ProtoMessage

func (*Ref) ProtoMessage()

func (*Ref) Reset

func (m *Ref) Reset()

func (*Ref) String

func (m *Ref) String() string

func (*Ref) XXX_DiscardUnknown

func (m *Ref) XXX_DiscardUnknown()

func (*Ref) XXX_Marshal

func (m *Ref) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Ref) XXX_Merge

func (m *Ref) XXX_Merge(src proto.Message)

func (*Ref) XXX_Size

func (m *Ref) XXX_Size() int

func (*Ref) XXX_Unmarshal

func (m *Ref) XXX_Unmarshal(b []byte) error

Jump to

Keyboard shortcuts

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