keys

package
v0.25.0 Latest Latest
Warning

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

Go to latest
Published: Apr 9, 2019 License: Apache-2.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultHost     = "localhost"
	DefaultPort     = "10997"
	DefaultHashType = "sha256"
	DefaultKeysDir  = ".keys"
	TestPort        = "0"
)
View Source
const (
	CryptoNone    = "none"
	CryptoAESGCM  = "scrypt-aes-gcm"
	HashEd25519   = "go-crypto-0.5.0"
	HashSecp256k1 = "btc"
)

Variables

View Source
var (
	ErrInvalidLengthKeys = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowKeys   = fmt.Errorf("proto: integer overflow")
)

Functions

func GetAllAddresses added in v0.19.0

func GetAllAddresses(dataDirPath string) (addresses []string, err error)

func IsValidKeyJson added in v0.19.0

func IsValidKeyJson(j []byte) []byte

returns the address if valid, nil otherwise

func RegisterKeysServer added in v0.20.0

func RegisterKeysServer(s *grpc.Server, srv KeysServer)

func StandAloneServer added in v0.25.0

func StandAloneServer(keysDir string, AllowBadFilePermissions bool) *grpc.Server

func WriteKeyFile added in v0.19.0

func WriteKeyFile(addr []byte, dataDirPath string, content []byte) (err error)

Types

type AddNameRequest added in v0.20.0

type AddNameRequest struct {
	Keyname              string   `protobuf:"bytes,1,opt,name=Keyname,proto3" json:"Keyname,omitempty"`
	Address              string   `protobuf:"bytes,2,opt,name=Address,proto3" json:"Address,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*AddNameRequest) Descriptor added in v0.20.0

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

func (*AddNameRequest) GetAddress added in v0.20.0

func (m *AddNameRequest) GetAddress() string

func (*AddNameRequest) GetKeyname added in v0.20.0

func (m *AddNameRequest) GetKeyname() string

func (*AddNameRequest) Marshal added in v0.20.0

func (m *AddNameRequest) Marshal() (dAtA []byte, err error)

func (*AddNameRequest) MarshalTo added in v0.20.0

func (m *AddNameRequest) MarshalTo(dAtA []byte) (int, error)

func (*AddNameRequest) ProtoMessage added in v0.20.0

func (*AddNameRequest) ProtoMessage()

func (*AddNameRequest) Reset added in v0.20.0

func (m *AddNameRequest) Reset()

func (*AddNameRequest) Size added in v0.20.0

func (m *AddNameRequest) Size() (n int)

func (*AddNameRequest) String added in v0.20.0

func (m *AddNameRequest) String() string

func (*AddNameRequest) Unmarshal added in v0.20.0

func (m *AddNameRequest) Unmarshal(dAtA []byte) error

func (*AddNameRequest) XXX_DiscardUnknown added in v0.23.0

func (m *AddNameRequest) XXX_DiscardUnknown()

func (*AddNameRequest) XXX_Marshal added in v0.23.0

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

func (*AddNameRequest) XXX_Merge added in v0.23.0

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

func (*AddNameRequest) XXX_MessageName added in v0.20.0

func (*AddNameRequest) XXX_MessageName() string

func (*AddNameRequest) XXX_Size added in v0.23.0

func (m *AddNameRequest) XXX_Size() int

func (*AddNameRequest) XXX_Unmarshal added in v0.23.0

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

type AddNameResponse added in v0.20.0

type AddNameResponse struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*AddNameResponse) Descriptor added in v0.20.0

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

func (*AddNameResponse) Marshal added in v0.20.0

func (m *AddNameResponse) Marshal() (dAtA []byte, err error)

func (*AddNameResponse) MarshalTo added in v0.20.0

func (m *AddNameResponse) MarshalTo(dAtA []byte) (int, error)

func (*AddNameResponse) ProtoMessage added in v0.20.0

func (*AddNameResponse) ProtoMessage()

func (*AddNameResponse) Reset added in v0.20.0

func (m *AddNameResponse) Reset()

func (*AddNameResponse) Size added in v0.20.0

func (m *AddNameResponse) Size() (n int)

func (*AddNameResponse) String added in v0.20.0

func (m *AddNameResponse) String() string

func (*AddNameResponse) Unmarshal added in v0.20.0

func (m *AddNameResponse) Unmarshal(dAtA []byte) error

func (*AddNameResponse) XXX_DiscardUnknown added in v0.23.0

func (m *AddNameResponse) XXX_DiscardUnknown()

func (*AddNameResponse) XXX_Marshal added in v0.23.0

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

func (*AddNameResponse) XXX_Merge added in v0.23.0

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

func (*AddNameResponse) XXX_MessageName added in v0.20.0

func (*AddNameResponse) XXX_MessageName() string

func (*AddNameResponse) XXX_Size added in v0.23.0

func (m *AddNameResponse) XXX_Size() int

func (*AddNameResponse) XXX_Unmarshal added in v0.23.0

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

type ExportRequest added in v0.20.0

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

func (*ExportRequest) Descriptor added in v0.20.0

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

func (*ExportRequest) GetAddress added in v0.20.0

func (m *ExportRequest) GetAddress() string

func (*ExportRequest) GetName added in v0.20.0

func (m *ExportRequest) GetName() string

func (*ExportRequest) GetPassphrase added in v0.20.0

func (m *ExportRequest) GetPassphrase() string

func (*ExportRequest) Marshal added in v0.20.0

func (m *ExportRequest) Marshal() (dAtA []byte, err error)

func (*ExportRequest) MarshalTo added in v0.20.0

func (m *ExportRequest) MarshalTo(dAtA []byte) (int, error)

func (*ExportRequest) ProtoMessage added in v0.20.0

func (*ExportRequest) ProtoMessage()

func (*ExportRequest) Reset added in v0.20.0

func (m *ExportRequest) Reset()

func (*ExportRequest) Size added in v0.20.0

func (m *ExportRequest) Size() (n int)

func (*ExportRequest) String added in v0.20.0

func (m *ExportRequest) String() string

func (*ExportRequest) Unmarshal added in v0.20.0

func (m *ExportRequest) Unmarshal(dAtA []byte) error

func (*ExportRequest) XXX_DiscardUnknown added in v0.23.0

func (m *ExportRequest) XXX_DiscardUnknown()

func (*ExportRequest) XXX_Marshal added in v0.23.0

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

func (*ExportRequest) XXX_Merge added in v0.23.0

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

func (*ExportRequest) XXX_MessageName added in v0.20.0

func (*ExportRequest) XXX_MessageName() string

func (*ExportRequest) XXX_Size added in v0.23.0

func (m *ExportRequest) XXX_Size() int

func (*ExportRequest) XXX_Unmarshal added in v0.23.0

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

type ExportResponse added in v0.20.0

type ExportResponse struct {
	Publickey            []byte   `protobuf:"bytes,1,opt,name=Publickey,proto3" json:"Publickey,omitempty"`
	Privatekey           []byte   `protobuf:"bytes,2,opt,name=Privatekey,proto3" json:"Privatekey,omitempty"`
	Address              []byte   `protobuf:"bytes,3,opt,name=Address,proto3" json:"Address,omitempty"`
	CurveType            string   `protobuf:"bytes,4,opt,name=CurveType,proto3" json:"CurveType,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*ExportResponse) Descriptor added in v0.20.0

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

func (*ExportResponse) GetAddress added in v0.20.0

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

func (*ExportResponse) GetCurveType added in v0.20.0

func (m *ExportResponse) GetCurveType() string

func (*ExportResponse) GetPrivatekey added in v0.20.0

func (m *ExportResponse) GetPrivatekey() []byte

func (*ExportResponse) GetPublickey added in v0.20.0

func (m *ExportResponse) GetPublickey() []byte

func (*ExportResponse) Marshal added in v0.20.0

func (m *ExportResponse) Marshal() (dAtA []byte, err error)

func (*ExportResponse) MarshalTo added in v0.20.0

func (m *ExportResponse) MarshalTo(dAtA []byte) (int, error)

func (*ExportResponse) ProtoMessage added in v0.20.0

func (*ExportResponse) ProtoMessage()

func (*ExportResponse) Reset added in v0.20.0

func (m *ExportResponse) Reset()

func (*ExportResponse) Size added in v0.20.0

func (m *ExportResponse) Size() (n int)

func (*ExportResponse) String added in v0.20.0

func (m *ExportResponse) String() string

func (*ExportResponse) Unmarshal added in v0.20.0

func (m *ExportResponse) Unmarshal(dAtA []byte) error

func (*ExportResponse) XXX_DiscardUnknown added in v0.23.0

func (m *ExportResponse) XXX_DiscardUnknown()

func (*ExportResponse) XXX_Marshal added in v0.23.0

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

func (*ExportResponse) XXX_Merge added in v0.23.0

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

func (*ExportResponse) XXX_MessageName added in v0.20.0

func (*ExportResponse) XXX_MessageName() string

func (*ExportResponse) XXX_Size added in v0.23.0

func (m *ExportResponse) XXX_Size() int

func (*ExportResponse) XXX_Unmarshal added in v0.23.0

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

type GenRequest added in v0.20.0

type GenRequest struct {
	Passphrase           string   `protobuf:"bytes,1,opt,name=Passphrase,proto3" json:"Passphrase,omitempty"`
	CurveType            string   `protobuf:"bytes,2,opt,name=CurveType,proto3" json:"CurveType,omitempty"`
	KeyName              string   `protobuf:"bytes,3,opt,name=KeyName,proto3" json:"KeyName,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*GenRequest) Descriptor added in v0.20.0

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

func (*GenRequest) GetCurveType added in v0.20.0

func (m *GenRequest) GetCurveType() string

func (*GenRequest) GetKeyName added in v0.20.0

func (m *GenRequest) GetKeyName() string

func (*GenRequest) GetPassphrase added in v0.20.0

func (m *GenRequest) GetPassphrase() string

func (*GenRequest) Marshal added in v0.20.0

func (m *GenRequest) Marshal() (dAtA []byte, err error)

func (*GenRequest) MarshalTo added in v0.20.0

func (m *GenRequest) MarshalTo(dAtA []byte) (int, error)

func (*GenRequest) ProtoMessage added in v0.20.0

func (*GenRequest) ProtoMessage()

func (*GenRequest) Reset added in v0.20.0

func (m *GenRequest) Reset()

func (*GenRequest) Size added in v0.20.0

func (m *GenRequest) Size() (n int)

func (*GenRequest) String added in v0.20.0

func (m *GenRequest) String() string

func (*GenRequest) Unmarshal added in v0.20.0

func (m *GenRequest) Unmarshal(dAtA []byte) error

func (*GenRequest) XXX_DiscardUnknown added in v0.23.0

func (m *GenRequest) XXX_DiscardUnknown()

func (*GenRequest) XXX_Marshal added in v0.23.0

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

func (*GenRequest) XXX_Merge added in v0.23.0

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

func (*GenRequest) XXX_MessageName added in v0.20.0

func (*GenRequest) XXX_MessageName() string

func (*GenRequest) XXX_Size added in v0.23.0

func (m *GenRequest) XXX_Size() int

func (*GenRequest) XXX_Unmarshal added in v0.23.0

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

type GenResponse added in v0.20.0

type GenResponse struct {
	Address              string   `protobuf:"bytes,1,opt,name=Address,proto3" json:"Address,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*GenResponse) Descriptor added in v0.20.0

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

func (*GenResponse) GetAddress added in v0.20.0

func (m *GenResponse) GetAddress() string

func (*GenResponse) Marshal added in v0.20.0

func (m *GenResponse) Marshal() (dAtA []byte, err error)

func (*GenResponse) MarshalTo added in v0.20.0

func (m *GenResponse) MarshalTo(dAtA []byte) (int, error)

func (*GenResponse) ProtoMessage added in v0.20.0

func (*GenResponse) ProtoMessage()

func (*GenResponse) Reset added in v0.20.0

func (m *GenResponse) Reset()

func (*GenResponse) Size added in v0.20.0

func (m *GenResponse) Size() (n int)

func (*GenResponse) String added in v0.20.0

func (m *GenResponse) String() string

func (*GenResponse) Unmarshal added in v0.20.0

func (m *GenResponse) Unmarshal(dAtA []byte) error

func (*GenResponse) XXX_DiscardUnknown added in v0.23.0

func (m *GenResponse) XXX_DiscardUnknown()

func (*GenResponse) XXX_Marshal added in v0.23.0

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

func (*GenResponse) XXX_Merge added in v0.23.0

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

func (*GenResponse) XXX_MessageName added in v0.20.0

func (*GenResponse) XXX_MessageName() string

func (*GenResponse) XXX_Size added in v0.23.0

func (m *GenResponse) XXX_Size() int

func (*GenResponse) XXX_Unmarshal added in v0.23.0

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

type HashRequest added in v0.20.0

type HashRequest struct {
	Hashtype             string   `protobuf:"bytes,1,opt,name=Hashtype,proto3" json:"Hashtype,omitempty"`
	Message              []byte   `protobuf:"bytes,2,opt,name=Message,proto3" json:"Message,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*HashRequest) Descriptor added in v0.20.0

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

func (*HashRequest) GetHashtype added in v0.20.0

func (m *HashRequest) GetHashtype() string

func (*HashRequest) GetMessage added in v0.20.0

func (m *HashRequest) GetMessage() []byte

func (*HashRequest) Marshal added in v0.20.0

func (m *HashRequest) Marshal() (dAtA []byte, err error)

func (*HashRequest) MarshalTo added in v0.20.0

func (m *HashRequest) MarshalTo(dAtA []byte) (int, error)

func (*HashRequest) ProtoMessage added in v0.20.0

func (*HashRequest) ProtoMessage()

func (*HashRequest) Reset added in v0.20.0

func (m *HashRequest) Reset()

func (*HashRequest) Size added in v0.20.0

func (m *HashRequest) Size() (n int)

func (*HashRequest) String added in v0.20.0

func (m *HashRequest) String() string

func (*HashRequest) Unmarshal added in v0.20.0

func (m *HashRequest) Unmarshal(dAtA []byte) error

func (*HashRequest) XXX_DiscardUnknown added in v0.23.0

func (m *HashRequest) XXX_DiscardUnknown()

func (*HashRequest) XXX_Marshal added in v0.23.0

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

func (*HashRequest) XXX_Merge added in v0.23.0

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

func (*HashRequest) XXX_MessageName added in v0.20.0

func (*HashRequest) XXX_MessageName() string

func (*HashRequest) XXX_Size added in v0.23.0

func (m *HashRequest) XXX_Size() int

func (*HashRequest) XXX_Unmarshal added in v0.23.0

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

type HashResponse added in v0.20.0

type HashResponse struct {
	Hash                 string   `protobuf:"bytes,1,opt,name=Hash,proto3" json:"Hash,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*HashResponse) Descriptor added in v0.20.0

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

func (*HashResponse) GetHash added in v0.20.0

func (m *HashResponse) GetHash() string

func (*HashResponse) Marshal added in v0.20.0

func (m *HashResponse) Marshal() (dAtA []byte, err error)

func (*HashResponse) MarshalTo added in v0.20.0

func (m *HashResponse) MarshalTo(dAtA []byte) (int, error)

func (*HashResponse) ProtoMessage added in v0.20.0

func (*HashResponse) ProtoMessage()

func (*HashResponse) Reset added in v0.20.0

func (m *HashResponse) Reset()

func (*HashResponse) Size added in v0.20.0

func (m *HashResponse) Size() (n int)

func (*HashResponse) String added in v0.20.0

func (m *HashResponse) String() string

func (*HashResponse) Unmarshal added in v0.20.0

func (m *HashResponse) Unmarshal(dAtA []byte) error

func (*HashResponse) XXX_DiscardUnknown added in v0.23.0

func (m *HashResponse) XXX_DiscardUnknown()

func (*HashResponse) XXX_Marshal added in v0.23.0

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

func (*HashResponse) XXX_Merge added in v0.23.0

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

func (*HashResponse) XXX_MessageName added in v0.20.0

func (*HashResponse) XXX_MessageName() string

func (*HashResponse) XXX_Size added in v0.23.0

func (m *HashResponse) XXX_Size() int

func (*HashResponse) XXX_Unmarshal added in v0.23.0

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

type ImportJSONRequest added in v0.20.0

type ImportJSONRequest struct {
	Passphrase           string   `protobuf:"bytes,1,opt,name=Passphrase,proto3" json:"Passphrase,omitempty"`
	JSON                 string   `protobuf:"bytes,2,opt,name=JSON,proto3" json:"JSON,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*ImportJSONRequest) Descriptor added in v0.20.0

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

func (*ImportJSONRequest) GetJSON added in v0.20.0

func (m *ImportJSONRequest) GetJSON() string

func (*ImportJSONRequest) GetPassphrase added in v0.20.0

func (m *ImportJSONRequest) GetPassphrase() string

func (*ImportJSONRequest) Marshal added in v0.20.0

func (m *ImportJSONRequest) Marshal() (dAtA []byte, err error)

func (*ImportJSONRequest) MarshalTo added in v0.20.0

func (m *ImportJSONRequest) MarshalTo(dAtA []byte) (int, error)

func (*ImportJSONRequest) ProtoMessage added in v0.20.0

func (*ImportJSONRequest) ProtoMessage()

func (*ImportJSONRequest) Reset added in v0.20.0

func (m *ImportJSONRequest) Reset()

func (*ImportJSONRequest) Size added in v0.20.0

func (m *ImportJSONRequest) Size() (n int)

func (*ImportJSONRequest) String added in v0.20.0

func (m *ImportJSONRequest) String() string

func (*ImportJSONRequest) Unmarshal added in v0.20.0

func (m *ImportJSONRequest) Unmarshal(dAtA []byte) error

func (*ImportJSONRequest) XXX_DiscardUnknown added in v0.23.0

func (m *ImportJSONRequest) XXX_DiscardUnknown()

func (*ImportJSONRequest) XXX_Marshal added in v0.23.0

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

func (*ImportJSONRequest) XXX_Merge added in v0.23.0

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

func (*ImportJSONRequest) XXX_MessageName added in v0.20.0

func (*ImportJSONRequest) XXX_MessageName() string

func (*ImportJSONRequest) XXX_Size added in v0.23.0

func (m *ImportJSONRequest) XXX_Size() int

func (*ImportJSONRequest) XXX_Unmarshal added in v0.23.0

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

type ImportRequest added in v0.20.0

type ImportRequest struct {
	Passphrase           string   `protobuf:"bytes,1,opt,name=Passphrase,proto3" json:"Passphrase,omitempty"`
	Name                 string   `protobuf:"bytes,2,opt,name=Name,proto3" json:"Name,omitempty"`
	CurveType            string   `protobuf:"bytes,3,opt,name=CurveType,proto3" json:"CurveType,omitempty"`
	KeyBytes             []byte   `protobuf:"bytes,4,opt,name=KeyBytes,proto3" json:"KeyBytes,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*ImportRequest) Descriptor added in v0.20.0

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

func (*ImportRequest) GetCurveType added in v0.20.0

func (m *ImportRequest) GetCurveType() string

func (*ImportRequest) GetKeyBytes added in v0.20.0

func (m *ImportRequest) GetKeyBytes() []byte

func (*ImportRequest) GetName added in v0.20.0

func (m *ImportRequest) GetName() string

func (*ImportRequest) GetPassphrase added in v0.20.0

func (m *ImportRequest) GetPassphrase() string

func (*ImportRequest) Marshal added in v0.20.0

func (m *ImportRequest) Marshal() (dAtA []byte, err error)

func (*ImportRequest) MarshalTo added in v0.20.0

func (m *ImportRequest) MarshalTo(dAtA []byte) (int, error)

func (*ImportRequest) ProtoMessage added in v0.20.0

func (*ImportRequest) ProtoMessage()

func (*ImportRequest) Reset added in v0.20.0

func (m *ImportRequest) Reset()

func (*ImportRequest) Size added in v0.20.0

func (m *ImportRequest) Size() (n int)

func (*ImportRequest) String added in v0.20.0

func (m *ImportRequest) String() string

func (*ImportRequest) Unmarshal added in v0.20.0

func (m *ImportRequest) Unmarshal(dAtA []byte) error

func (*ImportRequest) XXX_DiscardUnknown added in v0.23.0

func (m *ImportRequest) XXX_DiscardUnknown()

func (*ImportRequest) XXX_Marshal added in v0.23.0

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

func (*ImportRequest) XXX_Merge added in v0.23.0

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

func (*ImportRequest) XXX_MessageName added in v0.20.0

func (*ImportRequest) XXX_MessageName() string

func (*ImportRequest) XXX_Size added in v0.23.0

func (m *ImportRequest) XXX_Size() int

func (*ImportRequest) XXX_Unmarshal added in v0.23.0

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

type ImportResponse added in v0.20.0

type ImportResponse struct {
	Address              string   `protobuf:"bytes,1,opt,name=Address,proto3" json:"Address,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*ImportResponse) Descriptor added in v0.20.0

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

func (*ImportResponse) GetAddress added in v0.20.0

func (m *ImportResponse) GetAddress() string

func (*ImportResponse) Marshal added in v0.20.0

func (m *ImportResponse) Marshal() (dAtA []byte, err error)

func (*ImportResponse) MarshalTo added in v0.20.0

func (m *ImportResponse) MarshalTo(dAtA []byte) (int, error)

func (*ImportResponse) ProtoMessage added in v0.20.0

func (*ImportResponse) ProtoMessage()

func (*ImportResponse) Reset added in v0.20.0

func (m *ImportResponse) Reset()

func (*ImportResponse) Size added in v0.20.0

func (m *ImportResponse) Size() (n int)

func (*ImportResponse) String added in v0.20.0

func (m *ImportResponse) String() string

func (*ImportResponse) Unmarshal added in v0.20.0

func (m *ImportResponse) Unmarshal(dAtA []byte) error

func (*ImportResponse) XXX_DiscardUnknown added in v0.23.0

func (m *ImportResponse) XXX_DiscardUnknown()

func (*ImportResponse) XXX_Marshal added in v0.23.0

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

func (*ImportResponse) XXX_Merge added in v0.23.0

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

func (*ImportResponse) XXX_MessageName added in v0.20.0

func (*ImportResponse) XXX_MessageName() string

func (*ImportResponse) XXX_Size added in v0.23.0

func (m *ImportResponse) XXX_Size() int

func (*ImportResponse) XXX_Unmarshal added in v0.23.0

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

type Key added in v0.19.0

type Key struct {
	CurveType  crypto.CurveType
	Address    crypto.Address
	PublicKey  crypto.PublicKey
	PrivateKey crypto.PrivateKey
}

func DecryptKey added in v0.19.0

func DecryptKey(passphrase string, keyProtected *keyJSON) (*Key, error)

func NewKey added in v0.19.0

func NewKey(typ crypto.CurveType) (*Key, error)

func NewKeyFromPriv added in v0.19.0

func NewKeyFromPriv(curveType crypto.CurveType, PrivKeyBytes []byte) (*Key, error)

func NewKeyFromPub added in v0.19.0

func NewKeyFromPub(curveType crypto.CurveType, PubKeyBytes []byte) (*Key, error)

func (*Key) MarshalJSON added in v0.19.0

func (k *Key) MarshalJSON() (j []byte, err error)

func (*Key) Pubkey added in v0.19.0

func (k *Key) Pubkey() []byte

func (*Key) UnmarshalJSON added in v0.19.0

func (k *Key) UnmarshalJSON(j []byte) (err error)

type KeyClient

type KeyClient interface {
	// Sign returns the signature bytes for given message signed with the key associated with signAddress
	Sign(signAddress crypto.Address, message []byte) (*crypto.Signature, error)

	// PublicKey returns the public key associated with a given address
	PublicKey(address crypto.Address) (publicKey crypto.PublicKey, err error)

	// Generate requests that a key be generate within the keys instance and returns the address
	Generate(keyName string, keyType crypto.CurveType) (keyAddress crypto.Address, err error)

	// Get the address for a keyname or the adress itself
	GetAddressForKeyName(keyName string) (keyAddress crypto.Address, err error)

	// Returns nil if the keys instance is healthy, error otherwise
	HealthCheck() error
}

func NewLocalKeyClient added in v0.19.0

func NewLocalKeyClient(ks *KeyStore, logger *logging.Logger) KeyClient

func NewRemoteKeyClient added in v0.19.0

func NewRemoteKeyClient(rpcAddress string, logger *logging.Logger) (KeyClient, error)

keyClient.New returns a new monax-keys client for provided rpc location Monax-keys connects over http request-responses

type KeyID added in v0.20.0

type KeyID struct {
	Address              string   `protobuf:"bytes,1,opt,name=Address,proto3" json:"Address,omitempty"`
	KeyName              []string `protobuf:"bytes,2,rep,name=KeyName,proto3" json:"KeyName,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*KeyID) Descriptor added in v0.20.0

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

func (*KeyID) GetAddress added in v0.20.0

func (m *KeyID) GetAddress() string

func (*KeyID) GetKeyName added in v0.20.0

func (m *KeyID) GetKeyName() []string

func (*KeyID) Marshal added in v0.20.0

func (m *KeyID) Marshal() (dAtA []byte, err error)

func (*KeyID) MarshalTo added in v0.20.0

func (m *KeyID) MarshalTo(dAtA []byte) (int, error)

func (*KeyID) ProtoMessage added in v0.20.0

func (*KeyID) ProtoMessage()

func (*KeyID) Reset added in v0.20.0

func (m *KeyID) Reset()

func (*KeyID) Size added in v0.20.0

func (m *KeyID) Size() (n int)

func (*KeyID) String added in v0.20.0

func (m *KeyID) String() string

func (*KeyID) Unmarshal added in v0.20.0

func (m *KeyID) Unmarshal(dAtA []byte) error

func (*KeyID) XXX_DiscardUnknown added in v0.23.0

func (m *KeyID) XXX_DiscardUnknown()

func (*KeyID) XXX_Marshal added in v0.23.0

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

func (*KeyID) XXX_Merge added in v0.23.0

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

func (*KeyID) XXX_MessageName added in v0.20.0

func (*KeyID) XXX_MessageName() string

func (*KeyID) XXX_Size added in v0.23.0

func (m *KeyID) XXX_Size() int

func (*KeyID) XXX_Unmarshal added in v0.23.0

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

type KeyStore added in v0.19.0

type KeyStore struct {
	sync.Mutex
	AllowBadFilePermissions bool
	// contains filtered or unexported fields
}

func NewKeyStore added in v0.19.0

func NewKeyStore(dir string, AllowBadFilePermissions bool) *KeyStore

func (*KeyStore) AddName added in v0.19.0

func (k *KeyStore) AddName(ctx context.Context, in *AddNameRequest) (*AddNameResponse, error)

func (*KeyStore) AllKeys added in v0.19.0

func (ks *KeyStore) AllKeys() ([]*Key, error)

func (*KeyStore) DeleteKey added in v0.19.0

func (ks *KeyStore) DeleteKey(passphrase string, keyAddr []byte) (err error)

func (*KeyStore) Export added in v0.19.0

func (k *KeyStore) Export(ctx context.Context, in *ExportRequest) (*ExportResponse, error)

func (*KeyStore) Gen added in v0.19.0

func (ks *KeyStore) Gen(passphrase string, curveType crypto.CurveType) (key *Key, err error)

func (*KeyStore) GenerateKey added in v0.19.0

func (k *KeyStore) GenerateKey(ctx context.Context, in *GenRequest) (*GenResponse, error)

func (*KeyStore) GetAllAddresses added in v0.19.0

func (ks *KeyStore) GetAllAddresses() (addresses []string, err error)

func (*KeyStore) GetAllNames added in v0.19.0

func (ks *KeyStore) GetAllNames() (map[string]string, error)

func (*KeyStore) GetKey added in v0.19.0

func (ks *KeyStore) GetKey(passphrase string, keyAddr []byte) (*Key, error)

func (*KeyStore) GetKeyFile added in v0.19.0

func (ks *KeyStore) GetKeyFile(dataDirPath string, keyAddr []byte) (fileContent []byte, err error)

func (*KeyStore) Hash added in v0.19.0

func (k *KeyStore) Hash(ctx context.Context, in *HashRequest) (*HashResponse, error)

func (*KeyStore) Import added in v0.19.0

func (k *KeyStore) Import(ctx context.Context, in *ImportRequest) (*ImportResponse, error)

func (*KeyStore) ImportJSON added in v0.19.0

func (k *KeyStore) ImportJSON(ctx context.Context, in *ImportJSONRequest) (*ImportResponse, error)

func (*KeyStore) List added in v0.19.0

func (k *KeyStore) List(ctx context.Context, in *ListRequest) (*ListResponse, error)

func (*KeyStore) PublicKey added in v0.19.0

func (k *KeyStore) PublicKey(ctx context.Context, in *PubRequest) (*PubResponse, error)

func (*KeyStore) RemoveName added in v0.19.0

func (k *KeyStore) RemoveName(ctx context.Context, in *RemoveNameRequest) (*RemoveNameResponse, error)

func (*KeyStore) Sign added in v0.19.0

func (k *KeyStore) Sign(ctx context.Context, in *SignRequest) (*SignResponse, error)

func (*KeyStore) StoreKey added in v0.19.0

func (ks *KeyStore) StoreKey(passphrase string, key *Key) error

func (*KeyStore) StoreKeyEncrypted added in v0.19.0

func (ks *KeyStore) StoreKeyEncrypted(passphrase string, key *Key) error

func (*KeyStore) StoreKeyPlain added in v0.19.0

func (ks *KeyStore) StoreKeyPlain(key *Key) (err error)

func (*KeyStore) Verify added in v0.19.0

func (k *KeyStore) Verify(ctx context.Context, in *VerifyRequest) (*VerifyResponse, error)

type KeysClient added in v0.20.0

type KeysClient interface {
	GenerateKey(ctx context.Context, in *GenRequest, opts ...grpc.CallOption) (*GenResponse, error)
	PublicKey(ctx context.Context, in *PubRequest, opts ...grpc.CallOption) (*PubResponse, error)
	Sign(ctx context.Context, in *SignRequest, opts ...grpc.CallOption) (*SignResponse, error)
	Verify(ctx context.Context, in *VerifyRequest, opts ...grpc.CallOption) (*VerifyResponse, error)
	Import(ctx context.Context, in *ImportRequest, opts ...grpc.CallOption) (*ImportResponse, error)
	ImportJSON(ctx context.Context, in *ImportJSONRequest, opts ...grpc.CallOption) (*ImportResponse, error)
	Export(ctx context.Context, in *ExportRequest, opts ...grpc.CallOption) (*ExportResponse, error)
	Hash(ctx context.Context, in *HashRequest, opts ...grpc.CallOption) (*HashResponse, error)
	RemoveName(ctx context.Context, in *RemoveNameRequest, opts ...grpc.CallOption) (*RemoveNameResponse, error)
	List(ctx context.Context, in *ListRequest, opts ...grpc.CallOption) (*ListResponse, error)
	AddName(ctx context.Context, in *AddNameRequest, opts ...grpc.CallOption) (*AddNameResponse, error)
}

KeysClient is the client API for Keys service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewKeysClient added in v0.20.0

func NewKeysClient(cc *grpc.ClientConn) KeysClient

type KeysConfig added in v0.18.0

type KeysConfig struct {
	GRPCServiceEnabled      bool
	AllowBadFilePermissions bool
	RemoteAddress           string
	KeysDirectory           string
}

func DefaultKeysConfig added in v0.18.0

func DefaultKeysConfig() *KeysConfig

type ListRequest added in v0.20.0

type ListRequest struct {
	KeyName              string   `protobuf:"bytes,1,opt,name=KeyName,proto3" json:"KeyName,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*ListRequest) Descriptor added in v0.20.0

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

func (*ListRequest) GetKeyName added in v0.24.0

func (m *ListRequest) GetKeyName() string

func (*ListRequest) Marshal added in v0.20.0

func (m *ListRequest) Marshal() (dAtA []byte, err error)

func (*ListRequest) MarshalTo added in v0.20.0

func (m *ListRequest) MarshalTo(dAtA []byte) (int, error)

func (*ListRequest) ProtoMessage added in v0.20.0

func (*ListRequest) ProtoMessage()

func (*ListRequest) Reset added in v0.20.0

func (m *ListRequest) Reset()

func (*ListRequest) Size added in v0.20.0

func (m *ListRequest) Size() (n int)

func (*ListRequest) String added in v0.20.0

func (m *ListRequest) String() string

func (*ListRequest) Unmarshal added in v0.20.0

func (m *ListRequest) Unmarshal(dAtA []byte) error

func (*ListRequest) XXX_DiscardUnknown added in v0.23.0

func (m *ListRequest) XXX_DiscardUnknown()

func (*ListRequest) XXX_Marshal added in v0.23.0

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

func (*ListRequest) XXX_Merge added in v0.23.0

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

func (*ListRequest) XXX_MessageName added in v0.20.0

func (*ListRequest) XXX_MessageName() string

func (*ListRequest) XXX_Size added in v0.23.0

func (m *ListRequest) XXX_Size() int

func (*ListRequest) XXX_Unmarshal added in v0.23.0

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

type ListResponse added in v0.20.0

type ListResponse struct {
	Key                  []*KeyID `protobuf:"bytes,1,rep,name=key,proto3" json:"key,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*ListResponse) Descriptor added in v0.20.0

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

func (*ListResponse) GetKey added in v0.20.0

func (m *ListResponse) GetKey() []*KeyID

func (*ListResponse) Marshal added in v0.20.0

func (m *ListResponse) Marshal() (dAtA []byte, err error)

func (*ListResponse) MarshalTo added in v0.20.0

func (m *ListResponse) MarshalTo(dAtA []byte) (int, error)

func (*ListResponse) ProtoMessage added in v0.20.0

func (*ListResponse) ProtoMessage()

func (*ListResponse) Reset added in v0.20.0

func (m *ListResponse) Reset()

func (*ListResponse) Size added in v0.20.0

func (m *ListResponse) Size() (n int)

func (*ListResponse) String added in v0.20.0

func (m *ListResponse) String() string

func (*ListResponse) Unmarshal added in v0.20.0

func (m *ListResponse) Unmarshal(dAtA []byte) error

func (*ListResponse) XXX_DiscardUnknown added in v0.23.0

func (m *ListResponse) XXX_DiscardUnknown()

func (*ListResponse) XXX_Marshal added in v0.23.0

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

func (*ListResponse) XXX_Merge added in v0.23.0

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

func (*ListResponse) XXX_MessageName added in v0.20.0

func (*ListResponse) XXX_MessageName() string

func (*ListResponse) XXX_Size added in v0.23.0

func (m *ListResponse) XXX_Size() int

func (*ListResponse) XXX_Unmarshal added in v0.23.0

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

type PubRequest added in v0.20.0

type PubRequest struct {
	Address              string   `protobuf:"bytes,1,opt,name=Address,proto3" json:"Address,omitempty"`
	Name                 string   `protobuf:"bytes,2,opt,name=Name,proto3" json:"Name,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*PubRequest) Descriptor added in v0.20.0

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

func (*PubRequest) GetAddress added in v0.20.0

func (m *PubRequest) GetAddress() string

func (*PubRequest) GetName added in v0.20.0

func (m *PubRequest) GetName() string

func (*PubRequest) Marshal added in v0.20.0

func (m *PubRequest) Marshal() (dAtA []byte, err error)

func (*PubRequest) MarshalTo added in v0.20.0

func (m *PubRequest) MarshalTo(dAtA []byte) (int, error)

func (*PubRequest) ProtoMessage added in v0.20.0

func (*PubRequest) ProtoMessage()

func (*PubRequest) Reset added in v0.20.0

func (m *PubRequest) Reset()

func (*PubRequest) Size added in v0.20.0

func (m *PubRequest) Size() (n int)

func (*PubRequest) String added in v0.20.0

func (m *PubRequest) String() string

func (*PubRequest) Unmarshal added in v0.20.0

func (m *PubRequest) Unmarshal(dAtA []byte) error

func (*PubRequest) XXX_DiscardUnknown added in v0.23.0

func (m *PubRequest) XXX_DiscardUnknown()

func (*PubRequest) XXX_Marshal added in v0.23.0

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

func (*PubRequest) XXX_Merge added in v0.23.0

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

func (*PubRequest) XXX_MessageName added in v0.20.0

func (*PubRequest) XXX_MessageName() string

func (*PubRequest) XXX_Size added in v0.23.0

func (m *PubRequest) XXX_Size() int

func (*PubRequest) XXX_Unmarshal added in v0.23.0

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

type PubResponse added in v0.20.0

type PubResponse struct {
	PublicKey            []byte   `protobuf:"bytes,1,opt,name=PublicKey,proto3" json:"PublicKey,omitempty"`
	CurveType            string   `protobuf:"bytes,2,opt,name=CurveType,proto3" json:"CurveType,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*PubResponse) Descriptor added in v0.20.0

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

func (*PubResponse) GetCurveType added in v0.20.0

func (m *PubResponse) GetCurveType() string

func (*PubResponse) GetPublicKey added in v0.20.0

func (m *PubResponse) GetPublicKey() []byte

func (*PubResponse) Marshal added in v0.20.0

func (m *PubResponse) Marshal() (dAtA []byte, err error)

func (*PubResponse) MarshalTo added in v0.20.0

func (m *PubResponse) MarshalTo(dAtA []byte) (int, error)

func (*PubResponse) ProtoMessage added in v0.20.0

func (*PubResponse) ProtoMessage()

func (*PubResponse) Reset added in v0.20.0

func (m *PubResponse) Reset()

func (*PubResponse) Size added in v0.20.0

func (m *PubResponse) Size() (n int)

func (*PubResponse) String added in v0.20.0

func (m *PubResponse) String() string

func (*PubResponse) Unmarshal added in v0.20.0

func (m *PubResponse) Unmarshal(dAtA []byte) error

func (*PubResponse) XXX_DiscardUnknown added in v0.23.0

func (m *PubResponse) XXX_DiscardUnknown()

func (*PubResponse) XXX_Marshal added in v0.23.0

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

func (*PubResponse) XXX_Merge added in v0.23.0

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

func (*PubResponse) XXX_MessageName added in v0.20.0

func (*PubResponse) XXX_MessageName() string

func (*PubResponse) XXX_Size added in v0.23.0

func (m *PubResponse) XXX_Size() int

func (*PubResponse) XXX_Unmarshal added in v0.23.0

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

type RemoveNameRequest added in v0.20.0

type RemoveNameRequest struct {
	KeyName              string   `protobuf:"bytes,1,opt,name=KeyName,proto3" json:"KeyName,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*RemoveNameRequest) Descriptor added in v0.20.0

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

func (*RemoveNameRequest) GetKeyName added in v0.20.0

func (m *RemoveNameRequest) GetKeyName() string

func (*RemoveNameRequest) Marshal added in v0.20.0

func (m *RemoveNameRequest) Marshal() (dAtA []byte, err error)

func (*RemoveNameRequest) MarshalTo added in v0.20.0

func (m *RemoveNameRequest) MarshalTo(dAtA []byte) (int, error)

func (*RemoveNameRequest) ProtoMessage added in v0.20.0

func (*RemoveNameRequest) ProtoMessage()

func (*RemoveNameRequest) Reset added in v0.20.0

func (m *RemoveNameRequest) Reset()

func (*RemoveNameRequest) Size added in v0.20.0

func (m *RemoveNameRequest) Size() (n int)

func (*RemoveNameRequest) String added in v0.20.0

func (m *RemoveNameRequest) String() string

func (*RemoveNameRequest) Unmarshal added in v0.20.0

func (m *RemoveNameRequest) Unmarshal(dAtA []byte) error

func (*RemoveNameRequest) XXX_DiscardUnknown added in v0.23.0

func (m *RemoveNameRequest) XXX_DiscardUnknown()

func (*RemoveNameRequest) XXX_Marshal added in v0.23.0

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

func (*RemoveNameRequest) XXX_Merge added in v0.23.0

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

func (*RemoveNameRequest) XXX_MessageName added in v0.20.0

func (*RemoveNameRequest) XXX_MessageName() string

func (*RemoveNameRequest) XXX_Size added in v0.23.0

func (m *RemoveNameRequest) XXX_Size() int

func (*RemoveNameRequest) XXX_Unmarshal added in v0.23.0

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

type RemoveNameResponse added in v0.20.0

type RemoveNameResponse struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*RemoveNameResponse) Descriptor added in v0.20.0

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

func (*RemoveNameResponse) Marshal added in v0.20.0

func (m *RemoveNameResponse) Marshal() (dAtA []byte, err error)

func (*RemoveNameResponse) MarshalTo added in v0.20.0

func (m *RemoveNameResponse) MarshalTo(dAtA []byte) (int, error)

func (*RemoveNameResponse) ProtoMessage added in v0.20.0

func (*RemoveNameResponse) ProtoMessage()

func (*RemoveNameResponse) Reset added in v0.20.0

func (m *RemoveNameResponse) Reset()

func (*RemoveNameResponse) Size added in v0.20.0

func (m *RemoveNameResponse) Size() (n int)

func (*RemoveNameResponse) String added in v0.20.0

func (m *RemoveNameResponse) String() string

func (*RemoveNameResponse) Unmarshal added in v0.20.0

func (m *RemoveNameResponse) Unmarshal(dAtA []byte) error

func (*RemoveNameResponse) XXX_DiscardUnknown added in v0.23.0

func (m *RemoveNameResponse) XXX_DiscardUnknown()

func (*RemoveNameResponse) XXX_Marshal added in v0.23.0

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

func (*RemoveNameResponse) XXX_Merge added in v0.23.0

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

func (*RemoveNameResponse) XXX_MessageName added in v0.20.0

func (*RemoveNameResponse) XXX_MessageName() string

func (*RemoveNameResponse) XXX_Size added in v0.23.0

func (m *RemoveNameResponse) XXX_Size() int

func (*RemoveNameResponse) XXX_Unmarshal added in v0.23.0

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

type SignRequest added in v0.20.0

type SignRequest struct {
	Passphrase           string   `protobuf:"bytes,1,opt,name=Passphrase,proto3" json:"Passphrase,omitempty"`
	Address              string   `protobuf:"bytes,2,opt,name=Address,proto3" json:"Address,omitempty"`
	Name                 string   `protobuf:"bytes,3,opt,name=Name,proto3" json:"Name,omitempty"`
	Message              []byte   `protobuf:"bytes,4,opt,name=Message,proto3" json:"Message,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*SignRequest) Descriptor added in v0.20.0

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

func (*SignRequest) GetAddress added in v0.20.0

func (m *SignRequest) GetAddress() string

func (*SignRequest) GetMessage added in v0.20.0

func (m *SignRequest) GetMessage() []byte

func (*SignRequest) GetName added in v0.20.0

func (m *SignRequest) GetName() string

func (*SignRequest) GetPassphrase added in v0.20.0

func (m *SignRequest) GetPassphrase() string

func (*SignRequest) Marshal added in v0.20.0

func (m *SignRequest) Marshal() (dAtA []byte, err error)

func (*SignRequest) MarshalTo added in v0.20.0

func (m *SignRequest) MarshalTo(dAtA []byte) (int, error)

func (*SignRequest) ProtoMessage added in v0.20.0

func (*SignRequest) ProtoMessage()

func (*SignRequest) Reset added in v0.20.0

func (m *SignRequest) Reset()

func (*SignRequest) Size added in v0.20.0

func (m *SignRequest) Size() (n int)

func (*SignRequest) String added in v0.20.0

func (m *SignRequest) String() string

func (*SignRequest) Unmarshal added in v0.20.0

func (m *SignRequest) Unmarshal(dAtA []byte) error

func (*SignRequest) XXX_DiscardUnknown added in v0.23.0

func (m *SignRequest) XXX_DiscardUnknown()

func (*SignRequest) XXX_Marshal added in v0.23.0

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

func (*SignRequest) XXX_Merge added in v0.23.0

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

func (*SignRequest) XXX_MessageName added in v0.20.0

func (*SignRequest) XXX_MessageName() string

func (*SignRequest) XXX_Size added in v0.23.0

func (m *SignRequest) XXX_Size() int

func (*SignRequest) XXX_Unmarshal added in v0.23.0

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

type SignResponse added in v0.20.0

type SignResponse struct {
	Signature            *crypto.Signature `protobuf:"bytes,3,opt,name=Signature,proto3" json:"Signature,omitempty"`
	XXX_NoUnkeyedLiteral struct{}          `json:"-"`
	XXX_unrecognized     []byte            `json:"-"`
	XXX_sizecache        int32             `json:"-"`
}

func (*SignResponse) Descriptor added in v0.20.0

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

func (*SignResponse) GetSignature added in v0.20.0

func (m *SignResponse) GetSignature() *crypto.Signature

func (*SignResponse) Marshal added in v0.20.0

func (m *SignResponse) Marshal() (dAtA []byte, err error)

func (*SignResponse) MarshalTo added in v0.20.0

func (m *SignResponse) MarshalTo(dAtA []byte) (int, error)

func (*SignResponse) ProtoMessage added in v0.20.0

func (*SignResponse) ProtoMessage()

func (*SignResponse) Reset added in v0.20.0

func (m *SignResponse) Reset()

func (*SignResponse) Size added in v0.20.0

func (m *SignResponse) Size() (n int)

func (*SignResponse) String added in v0.20.0

func (m *SignResponse) String() string

func (*SignResponse) Unmarshal added in v0.20.0

func (m *SignResponse) Unmarshal(dAtA []byte) error

func (*SignResponse) XXX_DiscardUnknown added in v0.23.0

func (m *SignResponse) XXX_DiscardUnknown()

func (*SignResponse) XXX_Marshal added in v0.23.0

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

func (*SignResponse) XXX_Merge added in v0.23.0

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

func (*SignResponse) XXX_MessageName added in v0.20.0

func (*SignResponse) XXX_MessageName() string

func (*SignResponse) XXX_Size added in v0.23.0

func (m *SignResponse) XXX_Size() int

func (*SignResponse) XXX_Unmarshal added in v0.23.0

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

type Signer added in v0.18.0

type Signer struct {
	// contains filtered or unexported fields
}

func AddressableSigner added in v0.19.0

func AddressableSigner(keyClient KeyClient, address crypto.Address) (*Signer, error)

Creates a AddressableSigner that assumes the address holds an Ed25519 key

func (*Signer) GetAddress added in v0.23.0

func (ms *Signer) GetAddress() crypto.Address

func (*Signer) GetPublicKey added in v0.23.0

func (ms *Signer) GetPublicKey() crypto.PublicKey

func (*Signer) Sign added in v0.19.0

func (ms *Signer) Sign(messsage []byte) (*crypto.Signature, error)

type VerifyRequest added in v0.20.0

type VerifyRequest struct {
	PublicKey            []byte            `protobuf:"bytes,2,opt,name=PublicKey,proto3" json:"PublicKey,omitempty"`
	Message              []byte            `protobuf:"bytes,3,opt,name=Message,proto3" json:"Message,omitempty"`
	Signature            *crypto.Signature `protobuf:"bytes,5,opt,name=Signature,proto3" json:"Signature,omitempty"`
	XXX_NoUnkeyedLiteral struct{}          `json:"-"`
	XXX_unrecognized     []byte            `json:"-"`
	XXX_sizecache        int32             `json:"-"`
}

func (*VerifyRequest) Descriptor added in v0.20.0

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

func (*VerifyRequest) GetMessage added in v0.20.0

func (m *VerifyRequest) GetMessage() []byte

func (*VerifyRequest) GetPublicKey added in v0.20.0

func (m *VerifyRequest) GetPublicKey() []byte

func (*VerifyRequest) GetSignature added in v0.20.0

func (m *VerifyRequest) GetSignature() *crypto.Signature

func (*VerifyRequest) Marshal added in v0.20.0

func (m *VerifyRequest) Marshal() (dAtA []byte, err error)

func (*VerifyRequest) MarshalTo added in v0.20.0

func (m *VerifyRequest) MarshalTo(dAtA []byte) (int, error)

func (*VerifyRequest) ProtoMessage added in v0.20.0

func (*VerifyRequest) ProtoMessage()

func (*VerifyRequest) Reset added in v0.20.0

func (m *VerifyRequest) Reset()

func (*VerifyRequest) Size added in v0.20.0

func (m *VerifyRequest) Size() (n int)

func (*VerifyRequest) String added in v0.20.0

func (m *VerifyRequest) String() string

func (*VerifyRequest) Unmarshal added in v0.20.0

func (m *VerifyRequest) Unmarshal(dAtA []byte) error

func (*VerifyRequest) XXX_DiscardUnknown added in v0.23.0

func (m *VerifyRequest) XXX_DiscardUnknown()

func (*VerifyRequest) XXX_Marshal added in v0.23.0

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

func (*VerifyRequest) XXX_Merge added in v0.23.0

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

func (*VerifyRequest) XXX_MessageName added in v0.20.0

func (*VerifyRequest) XXX_MessageName() string

func (*VerifyRequest) XXX_Size added in v0.23.0

func (m *VerifyRequest) XXX_Size() int

func (*VerifyRequest) XXX_Unmarshal added in v0.23.0

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

type VerifyResponse added in v0.20.0

type VerifyResponse struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*VerifyResponse) Descriptor added in v0.20.0

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

func (*VerifyResponse) Marshal added in v0.20.0

func (m *VerifyResponse) Marshal() (dAtA []byte, err error)

func (*VerifyResponse) MarshalTo added in v0.20.0

func (m *VerifyResponse) MarshalTo(dAtA []byte) (int, error)

func (*VerifyResponse) ProtoMessage added in v0.20.0

func (*VerifyResponse) ProtoMessage()

func (*VerifyResponse) Reset added in v0.20.0

func (m *VerifyResponse) Reset()

func (*VerifyResponse) Size added in v0.20.0

func (m *VerifyResponse) Size() (n int)

func (*VerifyResponse) String added in v0.20.0

func (m *VerifyResponse) String() string

func (*VerifyResponse) Unmarshal added in v0.20.0

func (m *VerifyResponse) Unmarshal(dAtA []byte) error

func (*VerifyResponse) XXX_DiscardUnknown added in v0.23.0

func (m *VerifyResponse) XXX_DiscardUnknown()

func (*VerifyResponse) XXX_Marshal added in v0.23.0

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

func (*VerifyResponse) XXX_Merge added in v0.23.0

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

func (*VerifyResponse) XXX_MessageName added in v0.20.0

func (*VerifyResponse) XXX_MessageName() string

func (*VerifyResponse) XXX_Size added in v0.23.0

func (m *VerifyResponse) XXX_Size() int

func (*VerifyResponse) XXX_Unmarshal added in v0.23.0

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

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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