2018-10-23 03:30:02 +03:00
|
|
|
// Code generated by protoc-gen-go. DO NOT EDIT.
|
2021-04-28 16:30:59 +03:00
|
|
|
// versions:
|
|
|
|
// protoc-gen-go v1.23.0
|
|
|
|
// protoc v3.6.1
|
2018-10-31 07:14:48 +03:00
|
|
|
// source: signrpc/signer.proto
|
2018-10-23 03:30:02 +03:00
|
|
|
|
2019-05-15 16:07:30 +03:00
|
|
|
package signrpc
|
2018-10-23 03:30:02 +03:00
|
|
|
|
|
|
|
import (
|
2019-05-15 16:07:30 +03:00
|
|
|
context "context"
|
|
|
|
proto "github.com/golang/protobuf/proto"
|
2018-10-23 03:30:02 +03:00
|
|
|
grpc "google.golang.org/grpc"
|
2020-05-28 14:07:31 +03:00
|
|
|
codes "google.golang.org/grpc/codes"
|
|
|
|
status "google.golang.org/grpc/status"
|
2021-04-28 16:30:59 +03:00
|
|
|
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
|
|
|
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
|
|
|
reflect "reflect"
|
|
|
|
sync "sync"
|
2018-10-23 03:30:02 +03:00
|
|
|
)
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
const (
|
|
|
|
// Verify that this generated code is sufficiently up-to-date.
|
|
|
|
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
|
|
|
|
// Verify that runtime/protoimpl is sufficiently up-to-date.
|
|
|
|
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
|
|
|
)
|
2018-10-23 03:30:02 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
// This is a compile-time assertion that a sufficiently up-to-date version
|
|
|
|
// of the legacy proto package is being used.
|
|
|
|
const _ = proto.ProtoPackageIsVersion4
|
2018-10-23 03:30:02 +03:00
|
|
|
|
|
|
|
type KeyLocator struct {
|
2021-04-28 16:30:59 +03:00
|
|
|
state protoimpl.MessageState
|
|
|
|
sizeCache protoimpl.SizeCache
|
|
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
|
2020-05-06 17:51:14 +03:00
|
|
|
// The family of key being identified.
|
2018-12-11 13:42:43 +03:00
|
|
|
KeyFamily int32 `protobuf:"varint,1,opt,name=key_family,json=keyFamily,proto3" json:"key_family,omitempty"`
|
2020-05-06 17:51:14 +03:00
|
|
|
// The precise index of the key being identified.
|
2021-04-28 16:30:59 +03:00
|
|
|
KeyIndex int32 `protobuf:"varint,2,opt,name=key_index,json=keyIndex,proto3" json:"key_index,omitempty"`
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *KeyLocator) Reset() {
|
|
|
|
*x = KeyLocator{}
|
|
|
|
if protoimpl.UnsafeEnabled {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[0]
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
2019-05-15 16:07:30 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *KeyLocator) String() string {
|
|
|
|
return protoimpl.X.MessageStringOf(x)
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
2021-04-28 16:30:59 +03:00
|
|
|
|
|
|
|
func (*KeyLocator) ProtoMessage() {}
|
|
|
|
|
|
|
|
func (x *KeyLocator) ProtoReflect() protoreflect.Message {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[0]
|
|
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
if ms.LoadMessageInfo() == nil {
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
|
|
|
return ms
|
|
|
|
}
|
|
|
|
return mi.MessageOf(x)
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
// Deprecated: Use KeyLocator.ProtoReflect.Descriptor instead.
|
|
|
|
func (*KeyLocator) Descriptor() ([]byte, []int) {
|
|
|
|
return file_signrpc_signer_proto_rawDescGZIP(), []int{0}
|
|
|
|
}
|
2018-10-23 03:30:02 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *KeyLocator) GetKeyFamily() int32 {
|
|
|
|
if x != nil {
|
|
|
|
return x.KeyFamily
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
return 0
|
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *KeyLocator) GetKeyIndex() int32 {
|
|
|
|
if x != nil {
|
|
|
|
return x.KeyIndex
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
return 0
|
|
|
|
}
|
|
|
|
|
|
|
|
type KeyDescriptor struct {
|
2021-04-28 16:30:59 +03:00
|
|
|
state protoimpl.MessageState
|
|
|
|
sizeCache protoimpl.SizeCache
|
|
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2019-05-15 16:07:30 +03:00
|
|
|
//The raw bytes of the key being identified. Either this or the KeyLocator
|
|
|
|
//must be specified.
|
2018-12-04 08:26:35 +03:00
|
|
|
RawKeyBytes []byte `protobuf:"bytes,1,opt,name=raw_key_bytes,json=rawKeyBytes,proto3" json:"raw_key_bytes,omitempty"`
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2019-05-15 16:07:30 +03:00
|
|
|
//The key locator that identifies which key to use for signing. Either this
|
|
|
|
//or the raw bytes of the target key must be specified.
|
2021-04-28 16:30:59 +03:00
|
|
|
KeyLoc *KeyLocator `protobuf:"bytes,2,opt,name=key_loc,json=keyLoc,proto3" json:"key_loc,omitempty"`
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *KeyDescriptor) Reset() {
|
|
|
|
*x = KeyDescriptor{}
|
|
|
|
if protoimpl.UnsafeEnabled {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[1]
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
2019-05-15 16:07:30 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *KeyDescriptor) String() string {
|
|
|
|
return protoimpl.X.MessageStringOf(x)
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
2021-04-28 16:30:59 +03:00
|
|
|
|
|
|
|
func (*KeyDescriptor) ProtoMessage() {}
|
|
|
|
|
|
|
|
func (x *KeyDescriptor) ProtoReflect() protoreflect.Message {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[1]
|
|
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
if ms.LoadMessageInfo() == nil {
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
|
|
|
return ms
|
|
|
|
}
|
|
|
|
return mi.MessageOf(x)
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
// Deprecated: Use KeyDescriptor.ProtoReflect.Descriptor instead.
|
|
|
|
func (*KeyDescriptor) Descriptor() ([]byte, []int) {
|
|
|
|
return file_signrpc_signer_proto_rawDescGZIP(), []int{1}
|
|
|
|
}
|
2018-10-23 03:30:02 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *KeyDescriptor) GetRawKeyBytes() []byte {
|
|
|
|
if x != nil {
|
|
|
|
return x.RawKeyBytes
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *KeyDescriptor) GetKeyLoc() *KeyLocator {
|
|
|
|
if x != nil {
|
|
|
|
return x.KeyLoc
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
|
|
|
type TxOut struct {
|
2021-04-28 16:30:59 +03:00
|
|
|
state protoimpl.MessageState
|
|
|
|
sizeCache protoimpl.SizeCache
|
|
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
|
2020-05-06 17:51:14 +03:00
|
|
|
// The value of the output being spent.
|
2018-12-11 13:42:43 +03:00
|
|
|
Value int64 `protobuf:"varint,1,opt,name=value,proto3" json:"value,omitempty"`
|
2020-05-06 17:51:14 +03:00
|
|
|
// The script of the output being spent.
|
2021-04-28 16:30:59 +03:00
|
|
|
PkScript []byte `protobuf:"bytes,2,opt,name=pk_script,json=pkScript,proto3" json:"pk_script,omitempty"`
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *TxOut) Reset() {
|
|
|
|
*x = TxOut{}
|
|
|
|
if protoimpl.UnsafeEnabled {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[2]
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
2019-05-15 16:07:30 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *TxOut) String() string {
|
|
|
|
return protoimpl.X.MessageStringOf(x)
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
2021-04-28 16:30:59 +03:00
|
|
|
|
|
|
|
func (*TxOut) ProtoMessage() {}
|
|
|
|
|
|
|
|
func (x *TxOut) ProtoReflect() protoreflect.Message {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[2]
|
|
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
if ms.LoadMessageInfo() == nil {
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
|
|
|
return ms
|
|
|
|
}
|
|
|
|
return mi.MessageOf(x)
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
// Deprecated: Use TxOut.ProtoReflect.Descriptor instead.
|
|
|
|
func (*TxOut) Descriptor() ([]byte, []int) {
|
|
|
|
return file_signrpc_signer_proto_rawDescGZIP(), []int{2}
|
|
|
|
}
|
2018-10-23 03:30:02 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *TxOut) GetValue() int64 {
|
|
|
|
if x != nil {
|
|
|
|
return x.Value
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
return 0
|
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *TxOut) GetPkScript() []byte {
|
|
|
|
if x != nil {
|
|
|
|
return x.PkScript
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
|
|
|
type SignDescriptor struct {
|
2021-04-28 16:30:59 +03:00
|
|
|
state protoimpl.MessageState
|
|
|
|
sizeCache protoimpl.SizeCache
|
|
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2019-05-15 16:07:30 +03:00
|
|
|
//A descriptor that precisely describes *which* key to use for signing. This
|
|
|
|
//may provide the raw public key directly, or require the Signer to re-derive
|
|
|
|
//the key according to the populated derivation path.
|
2020-06-05 03:44:25 +03:00
|
|
|
//
|
|
|
|
//Note that if the key descriptor was obtained through walletrpc.DeriveKey,
|
|
|
|
//then the key locator MUST always be provided, since the derived keys are not
|
|
|
|
//persisted unlike with DeriveNextKey.
|
2018-12-11 13:42:43 +03:00
|
|
|
KeyDesc *KeyDescriptor `protobuf:"bytes,1,opt,name=key_desc,json=keyDesc,proto3" json:"key_desc,omitempty"`
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2019-05-15 16:07:30 +03:00
|
|
|
//A scalar value that will be added to the private key corresponding to the
|
|
|
|
//above public key to obtain the private key to be used to sign this input.
|
|
|
|
//This value is typically derived via the following computation:
|
2018-10-23 03:30:02 +03:00
|
|
|
//
|
|
|
|
// derivedKey = privkey + sha256(perCommitmentPoint || pubKey) mod N
|
|
|
|
SingleTweak []byte `protobuf:"bytes,2,opt,name=single_tweak,json=singleTweak,proto3" json:"single_tweak,omitempty"`
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2019-05-15 16:07:30 +03:00
|
|
|
//A private key that will be used in combination with its corresponding
|
|
|
|
//private key to derive the private key that is to be used to sign the target
|
|
|
|
//input. Within the Lightning protocol, this value is typically the
|
|
|
|
//commitment secret from a previously revoked commitment transaction. This
|
|
|
|
//value is in combination with two hash values, and the original private key
|
|
|
|
//to derive the private key to be used when signing.
|
2018-10-23 03:30:02 +03:00
|
|
|
//
|
|
|
|
// k = (privKey*sha256(pubKey || tweakPub) +
|
2019-05-15 16:07:30 +03:00
|
|
|
//tweakPriv*sha256(tweakPub || pubKey)) mod N
|
2018-10-23 03:30:02 +03:00
|
|
|
DoubleTweak []byte `protobuf:"bytes,3,opt,name=double_tweak,json=doubleTweak,proto3" json:"double_tweak,omitempty"`
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2019-05-15 16:07:30 +03:00
|
|
|
//The full script required to properly redeem the output. This field will
|
|
|
|
//only be populated if a p2wsh or a p2sh output is being signed.
|
2018-10-23 03:30:02 +03:00
|
|
|
WitnessScript []byte `protobuf:"bytes,4,opt,name=witness_script,json=witnessScript,proto3" json:"witness_script,omitempty"`
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2020-03-02 17:35:25 +03:00
|
|
|
//A description of the output being spent. The value and script MUST be
|
|
|
|
//provided.
|
2018-12-11 13:42:43 +03:00
|
|
|
Output *TxOut `protobuf:"bytes,5,opt,name=output,proto3" json:"output,omitempty"`
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2019-05-15 16:07:30 +03:00
|
|
|
//The target sighash type that should be used when generating the final
|
|
|
|
//sighash, and signature.
|
2018-12-11 13:42:43 +03:00
|
|
|
Sighash uint32 `protobuf:"varint,7,opt,name=sighash,proto3" json:"sighash,omitempty"`
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2019-05-15 16:07:30 +03:00
|
|
|
//The target input within the transaction that should be signed.
|
2021-04-28 16:30:59 +03:00
|
|
|
InputIndex int32 `protobuf:"varint,8,opt,name=input_index,json=inputIndex,proto3" json:"input_index,omitempty"`
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignDescriptor) Reset() {
|
|
|
|
*x = SignDescriptor{}
|
|
|
|
if protoimpl.UnsafeEnabled {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[3]
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
2019-05-15 16:07:30 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignDescriptor) String() string {
|
|
|
|
return protoimpl.X.MessageStringOf(x)
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
2021-04-28 16:30:59 +03:00
|
|
|
|
|
|
|
func (*SignDescriptor) ProtoMessage() {}
|
|
|
|
|
|
|
|
func (x *SignDescriptor) ProtoReflect() protoreflect.Message {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[3]
|
|
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
if ms.LoadMessageInfo() == nil {
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
|
|
|
return ms
|
|
|
|
}
|
|
|
|
return mi.MessageOf(x)
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
// Deprecated: Use SignDescriptor.ProtoReflect.Descriptor instead.
|
|
|
|
func (*SignDescriptor) Descriptor() ([]byte, []int) {
|
|
|
|
return file_signrpc_signer_proto_rawDescGZIP(), []int{3}
|
|
|
|
}
|
2018-10-23 03:30:02 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignDescriptor) GetKeyDesc() *KeyDescriptor {
|
|
|
|
if x != nil {
|
|
|
|
return x.KeyDesc
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignDescriptor) GetSingleTweak() []byte {
|
|
|
|
if x != nil {
|
|
|
|
return x.SingleTweak
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignDescriptor) GetDoubleTweak() []byte {
|
|
|
|
if x != nil {
|
|
|
|
return x.DoubleTweak
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignDescriptor) GetWitnessScript() []byte {
|
|
|
|
if x != nil {
|
|
|
|
return x.WitnessScript
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignDescriptor) GetOutput() *TxOut {
|
|
|
|
if x != nil {
|
|
|
|
return x.Output
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignDescriptor) GetSighash() uint32 {
|
|
|
|
if x != nil {
|
|
|
|
return x.Sighash
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
return 0
|
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignDescriptor) GetInputIndex() int32 {
|
|
|
|
if x != nil {
|
|
|
|
return x.InputIndex
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
return 0
|
|
|
|
}
|
|
|
|
|
|
|
|
type SignReq struct {
|
2021-04-28 16:30:59 +03:00
|
|
|
state protoimpl.MessageState
|
|
|
|
sizeCache protoimpl.SizeCache
|
|
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
|
2020-05-06 17:51:14 +03:00
|
|
|
// The raw bytes of the transaction to be signed.
|
2018-10-23 03:30:02 +03:00
|
|
|
RawTxBytes []byte `protobuf:"bytes,1,opt,name=raw_tx_bytes,json=rawTxBytes,proto3" json:"raw_tx_bytes,omitempty"`
|
2020-05-06 17:51:14 +03:00
|
|
|
// A set of sign descriptors, for each input to be signed.
|
2021-04-28 16:30:59 +03:00
|
|
|
SignDescs []*SignDescriptor `protobuf:"bytes,2,rep,name=sign_descs,json=signDescs,proto3" json:"sign_descs,omitempty"`
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignReq) Reset() {
|
|
|
|
*x = SignReq{}
|
|
|
|
if protoimpl.UnsafeEnabled {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[4]
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
2019-05-15 16:07:30 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignReq) String() string {
|
|
|
|
return protoimpl.X.MessageStringOf(x)
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
2021-04-28 16:30:59 +03:00
|
|
|
|
|
|
|
func (*SignReq) ProtoMessage() {}
|
|
|
|
|
|
|
|
func (x *SignReq) ProtoReflect() protoreflect.Message {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[4]
|
|
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
if ms.LoadMessageInfo() == nil {
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
|
|
|
return ms
|
|
|
|
}
|
|
|
|
return mi.MessageOf(x)
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
// Deprecated: Use SignReq.ProtoReflect.Descriptor instead.
|
|
|
|
func (*SignReq) Descriptor() ([]byte, []int) {
|
|
|
|
return file_signrpc_signer_proto_rawDescGZIP(), []int{4}
|
|
|
|
}
|
2018-10-23 03:30:02 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignReq) GetRawTxBytes() []byte {
|
|
|
|
if x != nil {
|
|
|
|
return x.RawTxBytes
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignReq) GetSignDescs() []*SignDescriptor {
|
|
|
|
if x != nil {
|
|
|
|
return x.SignDescs
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
|
|
|
type SignResp struct {
|
2021-04-28 16:30:59 +03:00
|
|
|
state protoimpl.MessageState
|
|
|
|
sizeCache protoimpl.SizeCache
|
|
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2019-05-15 16:07:30 +03:00
|
|
|
//A set of signatures realized in a fixed 64-byte format ordered in ascending
|
|
|
|
//input order.
|
2021-04-28 16:30:59 +03:00
|
|
|
RawSigs [][]byte `protobuf:"bytes,1,rep,name=raw_sigs,json=rawSigs,proto3" json:"raw_sigs,omitempty"`
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignResp) Reset() {
|
|
|
|
*x = SignResp{}
|
|
|
|
if protoimpl.UnsafeEnabled {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[5]
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
2019-05-15 16:07:30 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignResp) String() string {
|
|
|
|
return protoimpl.X.MessageStringOf(x)
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
2021-04-28 16:30:59 +03:00
|
|
|
|
|
|
|
func (*SignResp) ProtoMessage() {}
|
|
|
|
|
|
|
|
func (x *SignResp) ProtoReflect() protoreflect.Message {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[5]
|
|
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
if ms.LoadMessageInfo() == nil {
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
|
|
|
return ms
|
|
|
|
}
|
|
|
|
return mi.MessageOf(x)
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
// Deprecated: Use SignResp.ProtoReflect.Descriptor instead.
|
|
|
|
func (*SignResp) Descriptor() ([]byte, []int) {
|
|
|
|
return file_signrpc_signer_proto_rawDescGZIP(), []int{5}
|
|
|
|
}
|
2018-10-23 03:30:02 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignResp) GetRawSigs() [][]byte {
|
|
|
|
if x != nil {
|
|
|
|
return x.RawSigs
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
2018-11-29 07:08:00 +03:00
|
|
|
type InputScript struct {
|
2021-04-28 16:30:59 +03:00
|
|
|
state protoimpl.MessageState
|
|
|
|
sizeCache protoimpl.SizeCache
|
|
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
|
2020-05-06 17:51:14 +03:00
|
|
|
// The serializes witness stack for the specified input.
|
2018-11-29 07:08:00 +03:00
|
|
|
Witness [][]byte `protobuf:"bytes,1,rep,name=witness,proto3" json:"witness,omitempty"`
|
2020-05-13 10:19:27 +03:00
|
|
|
//
|
2019-05-15 16:07:30 +03:00
|
|
|
//The optional sig script for the specified witness that will only be set if
|
|
|
|
//the input specified is a nested p2sh witness program.
|
2021-04-28 16:30:59 +03:00
|
|
|
SigScript []byte `protobuf:"bytes,2,opt,name=sig_script,json=sigScript,proto3" json:"sig_script,omitempty"`
|
2018-11-29 07:08:00 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *InputScript) Reset() {
|
|
|
|
*x = InputScript{}
|
|
|
|
if protoimpl.UnsafeEnabled {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[6]
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
2019-05-15 16:07:30 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *InputScript) String() string {
|
|
|
|
return protoimpl.X.MessageStringOf(x)
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
2021-04-28 16:30:59 +03:00
|
|
|
|
|
|
|
func (*InputScript) ProtoMessage() {}
|
|
|
|
|
|
|
|
func (x *InputScript) ProtoReflect() protoreflect.Message {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[6]
|
|
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
if ms.LoadMessageInfo() == nil {
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
|
|
|
return ms
|
|
|
|
}
|
|
|
|
return mi.MessageOf(x)
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
// Deprecated: Use InputScript.ProtoReflect.Descriptor instead.
|
|
|
|
func (*InputScript) Descriptor() ([]byte, []int) {
|
|
|
|
return file_signrpc_signer_proto_rawDescGZIP(), []int{6}
|
|
|
|
}
|
2018-11-29 07:08:00 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *InputScript) GetWitness() [][]byte {
|
|
|
|
if x != nil {
|
|
|
|
return x.Witness
|
2018-11-29 07:08:00 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *InputScript) GetSigScript() []byte {
|
|
|
|
if x != nil {
|
|
|
|
return x.SigScript
|
2018-11-29 07:08:00 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
|
|
|
type InputScriptResp struct {
|
2021-04-28 16:30:59 +03:00
|
|
|
state protoimpl.MessageState
|
|
|
|
sizeCache protoimpl.SizeCache
|
|
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
|
2020-05-06 17:51:14 +03:00
|
|
|
// The set of fully valid input scripts requested.
|
2021-04-28 16:30:59 +03:00
|
|
|
InputScripts []*InputScript `protobuf:"bytes,1,rep,name=input_scripts,json=inputScripts,proto3" json:"input_scripts,omitempty"`
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *InputScriptResp) Reset() {
|
|
|
|
*x = InputScriptResp{}
|
|
|
|
if protoimpl.UnsafeEnabled {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[7]
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
2019-05-15 16:07:30 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *InputScriptResp) String() string {
|
|
|
|
return protoimpl.X.MessageStringOf(x)
|
2018-12-11 13:42:43 +03:00
|
|
|
}
|
2021-04-28 16:30:59 +03:00
|
|
|
|
|
|
|
func (*InputScriptResp) ProtoMessage() {}
|
|
|
|
|
|
|
|
func (x *InputScriptResp) ProtoReflect() protoreflect.Message {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[7]
|
|
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
if ms.LoadMessageInfo() == nil {
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
|
|
|
return ms
|
|
|
|
}
|
|
|
|
return mi.MessageOf(x)
|
2018-11-29 07:08:00 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
// Deprecated: Use InputScriptResp.ProtoReflect.Descriptor instead.
|
|
|
|
func (*InputScriptResp) Descriptor() ([]byte, []int) {
|
|
|
|
return file_signrpc_signer_proto_rawDescGZIP(), []int{7}
|
|
|
|
}
|
2018-11-29 07:08:00 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *InputScriptResp) GetInputScripts() []*InputScript {
|
|
|
|
if x != nil {
|
|
|
|
return x.InputScripts
|
2018-11-29 07:08:00 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
2019-12-10 11:48:49 +03:00
|
|
|
type SignMessageReq struct {
|
2021-04-28 16:30:59 +03:00
|
|
|
state protoimpl.MessageState
|
|
|
|
sizeCache protoimpl.SizeCache
|
|
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
|
2020-05-06 17:51:14 +03:00
|
|
|
// The message to be signed.
|
2019-12-10 11:48:49 +03:00
|
|
|
Msg []byte `protobuf:"bytes,1,opt,name=msg,proto3" json:"msg,omitempty"`
|
2020-05-06 17:51:14 +03:00
|
|
|
// The key locator that identifies which key to use for signing.
|
2021-04-28 16:30:59 +03:00
|
|
|
KeyLoc *KeyLocator `protobuf:"bytes,2,opt,name=key_loc,json=keyLoc,proto3" json:"key_loc,omitempty"`
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignMessageReq) Reset() {
|
|
|
|
*x = SignMessageReq{}
|
|
|
|
if protoimpl.UnsafeEnabled {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[8]
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignMessageReq) String() string {
|
|
|
|
return protoimpl.X.MessageStringOf(x)
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
2021-04-28 16:30:59 +03:00
|
|
|
|
|
|
|
func (*SignMessageReq) ProtoMessage() {}
|
|
|
|
|
|
|
|
func (x *SignMessageReq) ProtoReflect() protoreflect.Message {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[8]
|
|
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
if ms.LoadMessageInfo() == nil {
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
|
|
|
return ms
|
|
|
|
}
|
|
|
|
return mi.MessageOf(x)
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
// Deprecated: Use SignMessageReq.ProtoReflect.Descriptor instead.
|
|
|
|
func (*SignMessageReq) Descriptor() ([]byte, []int) {
|
|
|
|
return file_signrpc_signer_proto_rawDescGZIP(), []int{8}
|
|
|
|
}
|
2019-12-10 11:48:49 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignMessageReq) GetMsg() []byte {
|
|
|
|
if x != nil {
|
|
|
|
return x.Msg
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignMessageReq) GetKeyLoc() *KeyLocator {
|
|
|
|
if x != nil {
|
|
|
|
return x.KeyLoc
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
|
|
|
type SignMessageResp struct {
|
2021-04-28 16:30:59 +03:00
|
|
|
state protoimpl.MessageState
|
|
|
|
sizeCache protoimpl.SizeCache
|
|
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2019-12-13 04:20:33 +03:00
|
|
|
//The signature for the given message in the fixed-size LN wire format.
|
2021-04-28 16:30:59 +03:00
|
|
|
Signature []byte `protobuf:"bytes,1,opt,name=signature,proto3" json:"signature,omitempty"`
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignMessageResp) Reset() {
|
|
|
|
*x = SignMessageResp{}
|
|
|
|
if protoimpl.UnsafeEnabled {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[9]
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignMessageResp) String() string {
|
|
|
|
return protoimpl.X.MessageStringOf(x)
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
2021-04-28 16:30:59 +03:00
|
|
|
|
|
|
|
func (*SignMessageResp) ProtoMessage() {}
|
|
|
|
|
|
|
|
func (x *SignMessageResp) ProtoReflect() protoreflect.Message {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[9]
|
|
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
if ms.LoadMessageInfo() == nil {
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
|
|
|
return ms
|
|
|
|
}
|
|
|
|
return mi.MessageOf(x)
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
// Deprecated: Use SignMessageResp.ProtoReflect.Descriptor instead.
|
|
|
|
func (*SignMessageResp) Descriptor() ([]byte, []int) {
|
|
|
|
return file_signrpc_signer_proto_rawDescGZIP(), []int{9}
|
|
|
|
}
|
2019-12-10 11:48:49 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SignMessageResp) GetSignature() []byte {
|
|
|
|
if x != nil {
|
|
|
|
return x.Signature
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
|
|
|
type VerifyMessageReq struct {
|
2021-04-28 16:30:59 +03:00
|
|
|
state protoimpl.MessageState
|
|
|
|
sizeCache protoimpl.SizeCache
|
|
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
|
2020-05-06 17:51:14 +03:00
|
|
|
// The message over which the signature is to be verified.
|
2019-12-10 11:48:49 +03:00
|
|
|
Msg []byte `protobuf:"bytes,1,opt,name=msg,proto3" json:"msg,omitempty"`
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2019-12-13 04:20:33 +03:00
|
|
|
//The fixed-size LN wire encoded signature to be verified over the given
|
|
|
|
//message.
|
2019-12-10 11:48:49 +03:00
|
|
|
Signature []byte `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"`
|
2020-05-06 17:51:14 +03:00
|
|
|
// The public key the signature has to be valid for.
|
2021-04-28 16:30:59 +03:00
|
|
|
Pubkey []byte `protobuf:"bytes,3,opt,name=pubkey,proto3" json:"pubkey,omitempty"`
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *VerifyMessageReq) Reset() {
|
|
|
|
*x = VerifyMessageReq{}
|
|
|
|
if protoimpl.UnsafeEnabled {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[10]
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *VerifyMessageReq) String() string {
|
|
|
|
return protoimpl.X.MessageStringOf(x)
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
2021-04-28 16:30:59 +03:00
|
|
|
|
|
|
|
func (*VerifyMessageReq) ProtoMessage() {}
|
|
|
|
|
|
|
|
func (x *VerifyMessageReq) ProtoReflect() protoreflect.Message {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[10]
|
|
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
if ms.LoadMessageInfo() == nil {
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
|
|
|
return ms
|
|
|
|
}
|
|
|
|
return mi.MessageOf(x)
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
// Deprecated: Use VerifyMessageReq.ProtoReflect.Descriptor instead.
|
|
|
|
func (*VerifyMessageReq) Descriptor() ([]byte, []int) {
|
|
|
|
return file_signrpc_signer_proto_rawDescGZIP(), []int{10}
|
|
|
|
}
|
2019-12-10 11:48:49 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *VerifyMessageReq) GetMsg() []byte {
|
|
|
|
if x != nil {
|
|
|
|
return x.Msg
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *VerifyMessageReq) GetSignature() []byte {
|
|
|
|
if x != nil {
|
|
|
|
return x.Signature
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *VerifyMessageReq) GetPubkey() []byte {
|
|
|
|
if x != nil {
|
|
|
|
return x.Pubkey
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
|
|
|
type VerifyMessageResp struct {
|
2021-04-28 16:30:59 +03:00
|
|
|
state protoimpl.MessageState
|
|
|
|
sizeCache protoimpl.SizeCache
|
|
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
|
2020-05-06 17:51:14 +03:00
|
|
|
// Whether the signature was valid over the given message.
|
2021-04-28 16:30:59 +03:00
|
|
|
Valid bool `protobuf:"varint,1,opt,name=valid,proto3" json:"valid,omitempty"`
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *VerifyMessageResp) Reset() {
|
|
|
|
*x = VerifyMessageResp{}
|
|
|
|
if protoimpl.UnsafeEnabled {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[11]
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *VerifyMessageResp) String() string {
|
|
|
|
return protoimpl.X.MessageStringOf(x)
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
2021-04-28 16:30:59 +03:00
|
|
|
|
|
|
|
func (*VerifyMessageResp) ProtoMessage() {}
|
|
|
|
|
|
|
|
func (x *VerifyMessageResp) ProtoReflect() protoreflect.Message {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[11]
|
|
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
if ms.LoadMessageInfo() == nil {
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
|
|
|
return ms
|
|
|
|
}
|
|
|
|
return mi.MessageOf(x)
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
// Deprecated: Use VerifyMessageResp.ProtoReflect.Descriptor instead.
|
|
|
|
func (*VerifyMessageResp) Descriptor() ([]byte, []int) {
|
|
|
|
return file_signrpc_signer_proto_rawDescGZIP(), []int{11}
|
|
|
|
}
|
2019-12-10 11:48:49 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *VerifyMessageResp) GetValid() bool {
|
|
|
|
if x != nil {
|
|
|
|
return x.Valid
|
2019-12-10 11:48:49 +03:00
|
|
|
}
|
|
|
|
return false
|
|
|
|
}
|
|
|
|
|
2019-11-28 12:58:51 +03:00
|
|
|
type SharedKeyRequest struct {
|
2021-04-28 16:30:59 +03:00
|
|
|
state protoimpl.MessageState
|
|
|
|
sizeCache protoimpl.SizeCache
|
|
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
|
2019-11-28 12:58:51 +03:00
|
|
|
// The ephemeral public key to use for the DH key derivation.
|
2020-01-06 16:53:24 +03:00
|
|
|
EphemeralPubkey []byte `protobuf:"bytes,1,opt,name=ephemeral_pubkey,json=ephemeralPubkey,proto3" json:"ephemeral_pubkey,omitempty"`
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2020-07-28 00:39:12 +03:00
|
|
|
//Deprecated. The optional key locator of the local key that should be used.
|
|
|
|
//If this parameter is not set then the node's identity private key will be
|
|
|
|
//used.
|
2021-04-28 16:30:59 +03:00
|
|
|
//
|
|
|
|
// Deprecated: Do not use.
|
|
|
|
KeyLoc *KeyLocator `protobuf:"bytes,2,opt,name=key_loc,json=keyLoc,proto3" json:"key_loc,omitempty"`
|
2020-07-28 00:39:12 +03:00
|
|
|
//
|
|
|
|
//A key descriptor describes the key used for performing ECDH. Either a key
|
|
|
|
//locator or a raw public key is expected, if neither is supplied, defaults to
|
|
|
|
//the node's identity private key.
|
2021-04-28 16:30:59 +03:00
|
|
|
KeyDesc *KeyDescriptor `protobuf:"bytes,3,opt,name=key_desc,json=keyDesc,proto3" json:"key_desc,omitempty"`
|
2019-11-28 12:58:51 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SharedKeyRequest) Reset() {
|
|
|
|
*x = SharedKeyRequest{}
|
|
|
|
if protoimpl.UnsafeEnabled {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[12]
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
2019-11-28 12:58:51 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SharedKeyRequest) String() string {
|
|
|
|
return protoimpl.X.MessageStringOf(x)
|
2019-11-28 12:58:51 +03:00
|
|
|
}
|
2021-04-28 16:30:59 +03:00
|
|
|
|
|
|
|
func (*SharedKeyRequest) ProtoMessage() {}
|
|
|
|
|
|
|
|
func (x *SharedKeyRequest) ProtoReflect() protoreflect.Message {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[12]
|
|
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
if ms.LoadMessageInfo() == nil {
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
|
|
|
return ms
|
|
|
|
}
|
|
|
|
return mi.MessageOf(x)
|
2019-11-28 12:58:51 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
// Deprecated: Use SharedKeyRequest.ProtoReflect.Descriptor instead.
|
|
|
|
func (*SharedKeyRequest) Descriptor() ([]byte, []int) {
|
|
|
|
return file_signrpc_signer_proto_rawDescGZIP(), []int{12}
|
|
|
|
}
|
2019-11-28 12:58:51 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SharedKeyRequest) GetEphemeralPubkey() []byte {
|
|
|
|
if x != nil {
|
|
|
|
return x.EphemeralPubkey
|
2019-11-28 12:58:51 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
2020-07-28 00:39:12 +03:00
|
|
|
// Deprecated: Do not use.
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SharedKeyRequest) GetKeyLoc() *KeyLocator {
|
|
|
|
if x != nil {
|
|
|
|
return x.KeyLoc
|
2020-01-06 16:53:24 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SharedKeyRequest) GetKeyDesc() *KeyDescriptor {
|
|
|
|
if x != nil {
|
|
|
|
return x.KeyDesc
|
2020-07-28 00:39:12 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
2019-11-28 12:58:51 +03:00
|
|
|
type SharedKeyResponse struct {
|
2021-04-28 16:30:59 +03:00
|
|
|
state protoimpl.MessageState
|
|
|
|
sizeCache protoimpl.SizeCache
|
|
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
|
2019-11-28 12:58:51 +03:00
|
|
|
// The shared public key, hashed with sha256.
|
2021-04-28 16:30:59 +03:00
|
|
|
SharedKey []byte `protobuf:"bytes,1,opt,name=shared_key,json=sharedKey,proto3" json:"shared_key,omitempty"`
|
2019-11-28 12:58:51 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SharedKeyResponse) Reset() {
|
|
|
|
*x = SharedKeyResponse{}
|
|
|
|
if protoimpl.UnsafeEnabled {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[13]
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
2019-11-28 12:58:51 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SharedKeyResponse) String() string {
|
|
|
|
return protoimpl.X.MessageStringOf(x)
|
2019-11-28 12:58:51 +03:00
|
|
|
}
|
2021-04-28 16:30:59 +03:00
|
|
|
|
|
|
|
func (*SharedKeyResponse) ProtoMessage() {}
|
|
|
|
|
|
|
|
func (x *SharedKeyResponse) ProtoReflect() protoreflect.Message {
|
|
|
|
mi := &file_signrpc_signer_proto_msgTypes[13]
|
|
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
|
|
if ms.LoadMessageInfo() == nil {
|
|
|
|
ms.StoreMessageInfo(mi)
|
|
|
|
}
|
|
|
|
return ms
|
|
|
|
}
|
|
|
|
return mi.MessageOf(x)
|
2019-11-28 12:58:51 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
// Deprecated: Use SharedKeyResponse.ProtoReflect.Descriptor instead.
|
|
|
|
func (*SharedKeyResponse) Descriptor() ([]byte, []int) {
|
|
|
|
return file_signrpc_signer_proto_rawDescGZIP(), []int{13}
|
|
|
|
}
|
2019-11-28 12:58:51 +03:00
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (x *SharedKeyResponse) GetSharedKey() []byte {
|
|
|
|
if x != nil {
|
|
|
|
return x.SharedKey
|
2019-11-28 12:58:51 +03:00
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
var File_signrpc_signer_proto protoreflect.FileDescriptor
|
|
|
|
|
|
|
|
var file_signrpc_signer_proto_rawDesc = []byte{
|
|
|
|
0x0a, 0x14, 0x73, 0x69, 0x67, 0x6e, 0x72, 0x70, 0x63, 0x2f, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72,
|
|
|
|
0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x07, 0x73, 0x69, 0x67, 0x6e, 0x72, 0x70, 0x63, 0x22,
|
|
|
|
0x48, 0x0a, 0x0a, 0x4b, 0x65, 0x79, 0x4c, 0x6f, 0x63, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x1d, 0x0a,
|
|
|
|
0x0a, 0x6b, 0x65, 0x79, 0x5f, 0x66, 0x61, 0x6d, 0x69, 0x6c, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28,
|
|
|
|
0x05, 0x52, 0x09, 0x6b, 0x65, 0x79, 0x46, 0x61, 0x6d, 0x69, 0x6c, 0x79, 0x12, 0x1b, 0x0a, 0x09,
|
|
|
|
0x6b, 0x65, 0x79, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52,
|
|
|
|
0x08, 0x6b, 0x65, 0x79, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x22, 0x61, 0x0a, 0x0d, 0x4b, 0x65, 0x79,
|
|
|
|
0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x12, 0x22, 0x0a, 0x0d, 0x72, 0x61,
|
|
|
|
0x77, 0x5f, 0x6b, 0x65, 0x79, 0x5f, 0x62, 0x79, 0x74, 0x65, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28,
|
|
|
|
0x0c, 0x52, 0x0b, 0x72, 0x61, 0x77, 0x4b, 0x65, 0x79, 0x42, 0x79, 0x74, 0x65, 0x73, 0x12, 0x2c,
|
|
|
|
0x0a, 0x07, 0x6b, 0x65, 0x79, 0x5f, 0x6c, 0x6f, 0x63, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32,
|
|
|
|
0x13, 0x2e, 0x73, 0x69, 0x67, 0x6e, 0x72, 0x70, 0x63, 0x2e, 0x4b, 0x65, 0x79, 0x4c, 0x6f, 0x63,
|
|
|
|
0x61, 0x74, 0x6f, 0x72, 0x52, 0x06, 0x6b, 0x65, 0x79, 0x4c, 0x6f, 0x63, 0x22, 0x3a, 0x0a, 0x05,
|
|
|
|
0x54, 0x78, 0x4f, 0x75, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01,
|
|
|
|
0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x1b, 0x0a, 0x09, 0x70,
|
|
|
|
0x6b, 0x5f, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x08,
|
|
|
|
0x70, 0x6b, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x22, 0x93, 0x02, 0x0a, 0x0e, 0x53, 0x69, 0x67,
|
|
|
|
0x6e, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x12, 0x31, 0x0a, 0x08, 0x6b,
|
|
|
|
0x65, 0x79, 0x5f, 0x64, 0x65, 0x73, 0x63, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16, 0x2e,
|
|
|
|
0x73, 0x69, 0x67, 0x6e, 0x72, 0x70, 0x63, 0x2e, 0x4b, 0x65, 0x79, 0x44, 0x65, 0x73, 0x63, 0x72,
|
|
|
|
0x69, 0x70, 0x74, 0x6f, 0x72, 0x52, 0x07, 0x6b, 0x65, 0x79, 0x44, 0x65, 0x73, 0x63, 0x12, 0x21,
|
|
|
|
0x0a, 0x0c, 0x73, 0x69, 0x6e, 0x67, 0x6c, 0x65, 0x5f, 0x74, 0x77, 0x65, 0x61, 0x6b, 0x18, 0x02,
|
|
|
|
0x20, 0x01, 0x28, 0x0c, 0x52, 0x0b, 0x73, 0x69, 0x6e, 0x67, 0x6c, 0x65, 0x54, 0x77, 0x65, 0x61,
|
|
|
|
0x6b, 0x12, 0x21, 0x0a, 0x0c, 0x64, 0x6f, 0x75, 0x62, 0x6c, 0x65, 0x5f, 0x74, 0x77, 0x65, 0x61,
|
|
|
|
0x6b, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0b, 0x64, 0x6f, 0x75, 0x62, 0x6c, 0x65, 0x54,
|
|
|
|
0x77, 0x65, 0x61, 0x6b, 0x12, 0x25, 0x0a, 0x0e, 0x77, 0x69, 0x74, 0x6e, 0x65, 0x73, 0x73, 0x5f,
|
|
|
|
0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0d, 0x77, 0x69,
|
|
|
|
0x74, 0x6e, 0x65, 0x73, 0x73, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x12, 0x26, 0x0a, 0x06, 0x6f,
|
|
|
|
0x75, 0x74, 0x70, 0x75, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x73, 0x69,
|
|
|
|
0x67, 0x6e, 0x72, 0x70, 0x63, 0x2e, 0x54, 0x78, 0x4f, 0x75, 0x74, 0x52, 0x06, 0x6f, 0x75, 0x74,
|
|
|
|
0x70, 0x75, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x69, 0x67, 0x68, 0x61, 0x73, 0x68, 0x18, 0x07,
|
|
|
|
0x20, 0x01, 0x28, 0x0d, 0x52, 0x07, 0x73, 0x69, 0x67, 0x68, 0x61, 0x73, 0x68, 0x12, 0x1f, 0x0a,
|
|
|
|
0x0b, 0x69, 0x6e, 0x70, 0x75, 0x74, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0x08, 0x20, 0x01,
|
|
|
|
0x28, 0x05, 0x52, 0x0a, 0x69, 0x6e, 0x70, 0x75, 0x74, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x22, 0x63,
|
|
|
|
0x0a, 0x07, 0x53, 0x69, 0x67, 0x6e, 0x52, 0x65, 0x71, 0x12, 0x20, 0x0a, 0x0c, 0x72, 0x61, 0x77,
|
|
|
|
0x5f, 0x74, 0x78, 0x5f, 0x62, 0x79, 0x74, 0x65, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52,
|
|
|
|
0x0a, 0x72, 0x61, 0x77, 0x54, 0x78, 0x42, 0x79, 0x74, 0x65, 0x73, 0x12, 0x36, 0x0a, 0x0a, 0x73,
|
|
|
|
0x69, 0x67, 0x6e, 0x5f, 0x64, 0x65, 0x73, 0x63, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32,
|
|
|
|
0x17, 0x2e, 0x73, 0x69, 0x67, 0x6e, 0x72, 0x70, 0x63, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x44, 0x65,
|
|
|
|
0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x44, 0x65,
|
|
|
|
0x73, 0x63, 0x73, 0x22, 0x25, 0x0a, 0x08, 0x53, 0x69, 0x67, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x12,
|
|
|
|
0x19, 0x0a, 0x08, 0x72, 0x61, 0x77, 0x5f, 0x73, 0x69, 0x67, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28,
|
|
|
|
0x0c, 0x52, 0x07, 0x72, 0x61, 0x77, 0x53, 0x69, 0x67, 0x73, 0x22, 0x46, 0x0a, 0x0b, 0x49, 0x6e,
|
|
|
|
0x70, 0x75, 0x74, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x77, 0x69, 0x74,
|
|
|
|
0x6e, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0c, 0x52, 0x07, 0x77, 0x69, 0x74, 0x6e,
|
|
|
|
0x65, 0x73, 0x73, 0x12, 0x1d, 0x0a, 0x0a, 0x73, 0x69, 0x67, 0x5f, 0x73, 0x63, 0x72, 0x69, 0x70,
|
|
|
|
0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, 0x73, 0x69, 0x67, 0x53, 0x63, 0x72, 0x69,
|
|
|
|
0x70, 0x74, 0x22, 0x4c, 0x0a, 0x0f, 0x49, 0x6e, 0x70, 0x75, 0x74, 0x53, 0x63, 0x72, 0x69, 0x70,
|
|
|
|
0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x39, 0x0a, 0x0d, 0x69, 0x6e, 0x70, 0x75, 0x74, 0x5f, 0x73,
|
|
|
|
0x63, 0x72, 0x69, 0x70, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x73,
|
|
|
|
0x69, 0x67, 0x6e, 0x72, 0x70, 0x63, 0x2e, 0x49, 0x6e, 0x70, 0x75, 0x74, 0x53, 0x63, 0x72, 0x69,
|
|
|
|
0x70, 0x74, 0x52, 0x0c, 0x69, 0x6e, 0x70, 0x75, 0x74, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x73,
|
|
|
|
0x22, 0x50, 0x0a, 0x0e, 0x53, 0x69, 0x67, 0x6e, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x52,
|
|
|
|
0x65, 0x71, 0x12, 0x10, 0x0a, 0x03, 0x6d, 0x73, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52,
|
|
|
|
0x03, 0x6d, 0x73, 0x67, 0x12, 0x2c, 0x0a, 0x07, 0x6b, 0x65, 0x79, 0x5f, 0x6c, 0x6f, 0x63, 0x18,
|
|
|
|
0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x13, 0x2e, 0x73, 0x69, 0x67, 0x6e, 0x72, 0x70, 0x63, 0x2e,
|
|
|
|
0x4b, 0x65, 0x79, 0x4c, 0x6f, 0x63, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x06, 0x6b, 0x65, 0x79, 0x4c,
|
|
|
|
0x6f, 0x63, 0x22, 0x2f, 0x0a, 0x0f, 0x53, 0x69, 0x67, 0x6e, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67,
|
|
|
|
0x65, 0x52, 0x65, 0x73, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75,
|
|
|
|
0x72, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74,
|
|
|
|
0x75, 0x72, 0x65, 0x22, 0x5a, 0x0a, 0x10, 0x56, 0x65, 0x72, 0x69, 0x66, 0x79, 0x4d, 0x65, 0x73,
|
|
|
|
0x73, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x12, 0x10, 0x0a, 0x03, 0x6d, 0x73, 0x67, 0x18, 0x01,
|
|
|
|
0x20, 0x01, 0x28, 0x0c, 0x52, 0x03, 0x6d, 0x73, 0x67, 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x69, 0x67,
|
|
|
|
0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, 0x73, 0x69,
|
|
|
|
0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x75, 0x62, 0x6b, 0x65,
|
|
|
|
0x79, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x06, 0x70, 0x75, 0x62, 0x6b, 0x65, 0x79, 0x22,
|
|
|
|
0x29, 0x0a, 0x11, 0x56, 0x65, 0x72, 0x69, 0x66, 0x79, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65,
|
|
|
|
0x52, 0x65, 0x73, 0x70, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x18, 0x01, 0x20,
|
|
|
|
0x01, 0x28, 0x08, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x22, 0xa2, 0x01, 0x0a, 0x10, 0x53,
|
|
|
|
0x68, 0x61, 0x72, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12,
|
|
|
|
0x29, 0x0a, 0x10, 0x65, 0x70, 0x68, 0x65, 0x6d, 0x65, 0x72, 0x61, 0x6c, 0x5f, 0x70, 0x75, 0x62,
|
|
|
|
0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0f, 0x65, 0x70, 0x68, 0x65, 0x6d,
|
|
|
|
0x65, 0x72, 0x61, 0x6c, 0x50, 0x75, 0x62, 0x6b, 0x65, 0x79, 0x12, 0x30, 0x0a, 0x07, 0x6b, 0x65,
|
|
|
|
0x79, 0x5f, 0x6c, 0x6f, 0x63, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x13, 0x2e, 0x73, 0x69,
|
|
|
|
0x67, 0x6e, 0x72, 0x70, 0x63, 0x2e, 0x4b, 0x65, 0x79, 0x4c, 0x6f, 0x63, 0x61, 0x74, 0x6f, 0x72,
|
|
|
|
0x42, 0x02, 0x18, 0x01, 0x52, 0x06, 0x6b, 0x65, 0x79, 0x4c, 0x6f, 0x63, 0x12, 0x31, 0x0a, 0x08,
|
|
|
|
0x6b, 0x65, 0x79, 0x5f, 0x64, 0x65, 0x73, 0x63, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16,
|
|
|
|
0x2e, 0x73, 0x69, 0x67, 0x6e, 0x72, 0x70, 0x63, 0x2e, 0x4b, 0x65, 0x79, 0x44, 0x65, 0x73, 0x63,
|
|
|
|
0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x52, 0x07, 0x6b, 0x65, 0x79, 0x44, 0x65, 0x73, 0x63, 0x22,
|
|
|
|
0x32, 0x0a, 0x11, 0x53, 0x68, 0x61, 0x72, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x52, 0x65, 0x73, 0x70,
|
|
|
|
0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x73, 0x68, 0x61, 0x72, 0x65, 0x64, 0x5f, 0x6b,
|
|
|
|
0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, 0x73, 0x68, 0x61, 0x72, 0x65, 0x64,
|
|
|
|
0x4b, 0x65, 0x79, 0x32, 0xd4, 0x02, 0x0a, 0x06, 0x53, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x12, 0x34,
|
|
|
|
0x0a, 0x0d, 0x53, 0x69, 0x67, 0x6e, 0x4f, 0x75, 0x74, 0x70, 0x75, 0x74, 0x52, 0x61, 0x77, 0x12,
|
|
|
|
0x10, 0x2e, 0x73, 0x69, 0x67, 0x6e, 0x72, 0x70, 0x63, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x52, 0x65,
|
|
|
|
0x71, 0x1a, 0x11, 0x2e, 0x73, 0x69, 0x67, 0x6e, 0x72, 0x70, 0x63, 0x2e, 0x53, 0x69, 0x67, 0x6e,
|
|
|
|
0x52, 0x65, 0x73, 0x70, 0x12, 0x40, 0x0a, 0x12, 0x43, 0x6f, 0x6d, 0x70, 0x75, 0x74, 0x65, 0x49,
|
|
|
|
0x6e, 0x70, 0x75, 0x74, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x12, 0x10, 0x2e, 0x73, 0x69, 0x67,
|
|
|
|
0x6e, 0x72, 0x70, 0x63, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x52, 0x65, 0x71, 0x1a, 0x18, 0x2e, 0x73,
|
|
|
|
0x69, 0x67, 0x6e, 0x72, 0x70, 0x63, 0x2e, 0x49, 0x6e, 0x70, 0x75, 0x74, 0x53, 0x63, 0x72, 0x69,
|
|
|
|
0x70, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x40, 0x0a, 0x0b, 0x53, 0x69, 0x67, 0x6e, 0x4d, 0x65,
|
|
|
|
0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x17, 0x2e, 0x73, 0x69, 0x67, 0x6e, 0x72, 0x70, 0x63, 0x2e,
|
|
|
|
0x53, 0x69, 0x67, 0x6e, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x18,
|
|
|
|
0x2e, 0x73, 0x69, 0x67, 0x6e, 0x72, 0x70, 0x63, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x4d, 0x65, 0x73,
|
|
|
|
0x73, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x12, 0x46, 0x0a, 0x0d, 0x56, 0x65, 0x72, 0x69,
|
|
|
|
0x66, 0x79, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x19, 0x2e, 0x73, 0x69, 0x67, 0x6e,
|
|
|
|
0x72, 0x70, 0x63, 0x2e, 0x56, 0x65, 0x72, 0x69, 0x66, 0x79, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67,
|
|
|
|
0x65, 0x52, 0x65, 0x71, 0x1a, 0x1a, 0x2e, 0x73, 0x69, 0x67, 0x6e, 0x72, 0x70, 0x63, 0x2e, 0x56,
|
|
|
|
0x65, 0x72, 0x69, 0x66, 0x79, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70,
|
|
|
|
0x12, 0x48, 0x0a, 0x0f, 0x44, 0x65, 0x72, 0x69, 0x76, 0x65, 0x53, 0x68, 0x61, 0x72, 0x65, 0x64,
|
|
|
|
0x4b, 0x65, 0x79, 0x12, 0x19, 0x2e, 0x73, 0x69, 0x67, 0x6e, 0x72, 0x70, 0x63, 0x2e, 0x53, 0x68,
|
|
|
|
0x61, 0x72, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1a,
|
|
|
|
0x2e, 0x73, 0x69, 0x67, 0x6e, 0x72, 0x70, 0x63, 0x2e, 0x53, 0x68, 0x61, 0x72, 0x65, 0x64, 0x4b,
|
|
|
|
0x65, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x2f, 0x5a, 0x2d, 0x67, 0x69,
|
|
|
|
0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x6c, 0x69, 0x67, 0x68, 0x74, 0x6e, 0x69,
|
|
|
|
0x6e, 0x67, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x6c, 0x6e, 0x64, 0x2f, 0x6c, 0x6e,
|
|
|
|
0x72, 0x70, 0x63, 0x2f, 0x73, 0x69, 0x67, 0x6e, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f,
|
|
|
|
0x74, 0x6f, 0x33,
|
|
|
|
}
|
|
|
|
|
|
|
|
var (
|
|
|
|
file_signrpc_signer_proto_rawDescOnce sync.Once
|
|
|
|
file_signrpc_signer_proto_rawDescData = file_signrpc_signer_proto_rawDesc
|
|
|
|
)
|
|
|
|
|
|
|
|
func file_signrpc_signer_proto_rawDescGZIP() []byte {
|
|
|
|
file_signrpc_signer_proto_rawDescOnce.Do(func() {
|
|
|
|
file_signrpc_signer_proto_rawDescData = protoimpl.X.CompressGZIP(file_signrpc_signer_proto_rawDescData)
|
|
|
|
})
|
|
|
|
return file_signrpc_signer_proto_rawDescData
|
|
|
|
}
|
|
|
|
|
|
|
|
var file_signrpc_signer_proto_msgTypes = make([]protoimpl.MessageInfo, 14)
|
|
|
|
var file_signrpc_signer_proto_goTypes = []interface{}{
|
|
|
|
(*KeyLocator)(nil), // 0: signrpc.KeyLocator
|
|
|
|
(*KeyDescriptor)(nil), // 1: signrpc.KeyDescriptor
|
|
|
|
(*TxOut)(nil), // 2: signrpc.TxOut
|
|
|
|
(*SignDescriptor)(nil), // 3: signrpc.SignDescriptor
|
|
|
|
(*SignReq)(nil), // 4: signrpc.SignReq
|
|
|
|
(*SignResp)(nil), // 5: signrpc.SignResp
|
|
|
|
(*InputScript)(nil), // 6: signrpc.InputScript
|
|
|
|
(*InputScriptResp)(nil), // 7: signrpc.InputScriptResp
|
|
|
|
(*SignMessageReq)(nil), // 8: signrpc.SignMessageReq
|
|
|
|
(*SignMessageResp)(nil), // 9: signrpc.SignMessageResp
|
|
|
|
(*VerifyMessageReq)(nil), // 10: signrpc.VerifyMessageReq
|
|
|
|
(*VerifyMessageResp)(nil), // 11: signrpc.VerifyMessageResp
|
|
|
|
(*SharedKeyRequest)(nil), // 12: signrpc.SharedKeyRequest
|
|
|
|
(*SharedKeyResponse)(nil), // 13: signrpc.SharedKeyResponse
|
|
|
|
}
|
|
|
|
var file_signrpc_signer_proto_depIdxs = []int32{
|
|
|
|
0, // 0: signrpc.KeyDescriptor.key_loc:type_name -> signrpc.KeyLocator
|
|
|
|
1, // 1: signrpc.SignDescriptor.key_desc:type_name -> signrpc.KeyDescriptor
|
|
|
|
2, // 2: signrpc.SignDescriptor.output:type_name -> signrpc.TxOut
|
|
|
|
3, // 3: signrpc.SignReq.sign_descs:type_name -> signrpc.SignDescriptor
|
|
|
|
6, // 4: signrpc.InputScriptResp.input_scripts:type_name -> signrpc.InputScript
|
|
|
|
0, // 5: signrpc.SignMessageReq.key_loc:type_name -> signrpc.KeyLocator
|
|
|
|
0, // 6: signrpc.SharedKeyRequest.key_loc:type_name -> signrpc.KeyLocator
|
|
|
|
1, // 7: signrpc.SharedKeyRequest.key_desc:type_name -> signrpc.KeyDescriptor
|
|
|
|
4, // 8: signrpc.Signer.SignOutputRaw:input_type -> signrpc.SignReq
|
|
|
|
4, // 9: signrpc.Signer.ComputeInputScript:input_type -> signrpc.SignReq
|
|
|
|
8, // 10: signrpc.Signer.SignMessage:input_type -> signrpc.SignMessageReq
|
|
|
|
10, // 11: signrpc.Signer.VerifyMessage:input_type -> signrpc.VerifyMessageReq
|
|
|
|
12, // 12: signrpc.Signer.DeriveSharedKey:input_type -> signrpc.SharedKeyRequest
|
|
|
|
5, // 13: signrpc.Signer.SignOutputRaw:output_type -> signrpc.SignResp
|
|
|
|
7, // 14: signrpc.Signer.ComputeInputScript:output_type -> signrpc.InputScriptResp
|
|
|
|
9, // 15: signrpc.Signer.SignMessage:output_type -> signrpc.SignMessageResp
|
|
|
|
11, // 16: signrpc.Signer.VerifyMessage:output_type -> signrpc.VerifyMessageResp
|
|
|
|
13, // 17: signrpc.Signer.DeriveSharedKey:output_type -> signrpc.SharedKeyResponse
|
|
|
|
13, // [13:18] is the sub-list for method output_type
|
|
|
|
8, // [8:13] is the sub-list for method input_type
|
|
|
|
8, // [8:8] is the sub-list for extension type_name
|
|
|
|
8, // [8:8] is the sub-list for extension extendee
|
|
|
|
0, // [0:8] is the sub-list for field type_name
|
|
|
|
}
|
|
|
|
|
|
|
|
func init() { file_signrpc_signer_proto_init() }
|
|
|
|
func file_signrpc_signer_proto_init() {
|
|
|
|
if File_signrpc_signer_proto != nil {
|
|
|
|
return
|
|
|
|
}
|
|
|
|
if !protoimpl.UnsafeEnabled {
|
|
|
|
file_signrpc_signer_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
|
|
|
switch v := v.(*KeyLocator); i {
|
|
|
|
case 0:
|
|
|
|
return &v.state
|
|
|
|
case 1:
|
|
|
|
return &v.sizeCache
|
|
|
|
case 2:
|
|
|
|
return &v.unknownFields
|
|
|
|
default:
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
}
|
|
|
|
file_signrpc_signer_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
|
|
|
|
switch v := v.(*KeyDescriptor); i {
|
|
|
|
case 0:
|
|
|
|
return &v.state
|
|
|
|
case 1:
|
|
|
|
return &v.sizeCache
|
|
|
|
case 2:
|
|
|
|
return &v.unknownFields
|
|
|
|
default:
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
}
|
|
|
|
file_signrpc_signer_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
|
|
|
|
switch v := v.(*TxOut); i {
|
|
|
|
case 0:
|
|
|
|
return &v.state
|
|
|
|
case 1:
|
|
|
|
return &v.sizeCache
|
|
|
|
case 2:
|
|
|
|
return &v.unknownFields
|
|
|
|
default:
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
}
|
|
|
|
file_signrpc_signer_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
|
|
|
|
switch v := v.(*SignDescriptor); i {
|
|
|
|
case 0:
|
|
|
|
return &v.state
|
|
|
|
case 1:
|
|
|
|
return &v.sizeCache
|
|
|
|
case 2:
|
|
|
|
return &v.unknownFields
|
|
|
|
default:
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
}
|
|
|
|
file_signrpc_signer_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
|
|
|
|
switch v := v.(*SignReq); i {
|
|
|
|
case 0:
|
|
|
|
return &v.state
|
|
|
|
case 1:
|
|
|
|
return &v.sizeCache
|
|
|
|
case 2:
|
|
|
|
return &v.unknownFields
|
|
|
|
default:
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
}
|
|
|
|
file_signrpc_signer_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
|
|
|
|
switch v := v.(*SignResp); i {
|
|
|
|
case 0:
|
|
|
|
return &v.state
|
|
|
|
case 1:
|
|
|
|
return &v.sizeCache
|
|
|
|
case 2:
|
|
|
|
return &v.unknownFields
|
|
|
|
default:
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
}
|
|
|
|
file_signrpc_signer_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
|
|
|
|
switch v := v.(*InputScript); i {
|
|
|
|
case 0:
|
|
|
|
return &v.state
|
|
|
|
case 1:
|
|
|
|
return &v.sizeCache
|
|
|
|
case 2:
|
|
|
|
return &v.unknownFields
|
|
|
|
default:
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
}
|
|
|
|
file_signrpc_signer_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
|
|
|
|
switch v := v.(*InputScriptResp); i {
|
|
|
|
case 0:
|
|
|
|
return &v.state
|
|
|
|
case 1:
|
|
|
|
return &v.sizeCache
|
|
|
|
case 2:
|
|
|
|
return &v.unknownFields
|
|
|
|
default:
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
}
|
|
|
|
file_signrpc_signer_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
|
|
|
|
switch v := v.(*SignMessageReq); i {
|
|
|
|
case 0:
|
|
|
|
return &v.state
|
|
|
|
case 1:
|
|
|
|
return &v.sizeCache
|
|
|
|
case 2:
|
|
|
|
return &v.unknownFields
|
|
|
|
default:
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
}
|
|
|
|
file_signrpc_signer_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} {
|
|
|
|
switch v := v.(*SignMessageResp); i {
|
|
|
|
case 0:
|
|
|
|
return &v.state
|
|
|
|
case 1:
|
|
|
|
return &v.sizeCache
|
|
|
|
case 2:
|
|
|
|
return &v.unknownFields
|
|
|
|
default:
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
}
|
|
|
|
file_signrpc_signer_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} {
|
|
|
|
switch v := v.(*VerifyMessageReq); i {
|
|
|
|
case 0:
|
|
|
|
return &v.state
|
|
|
|
case 1:
|
|
|
|
return &v.sizeCache
|
|
|
|
case 2:
|
|
|
|
return &v.unknownFields
|
|
|
|
default:
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
}
|
|
|
|
file_signrpc_signer_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} {
|
|
|
|
switch v := v.(*VerifyMessageResp); i {
|
|
|
|
case 0:
|
|
|
|
return &v.state
|
|
|
|
case 1:
|
|
|
|
return &v.sizeCache
|
|
|
|
case 2:
|
|
|
|
return &v.unknownFields
|
|
|
|
default:
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
}
|
|
|
|
file_signrpc_signer_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} {
|
|
|
|
switch v := v.(*SharedKeyRequest); i {
|
|
|
|
case 0:
|
|
|
|
return &v.state
|
|
|
|
case 1:
|
|
|
|
return &v.sizeCache
|
|
|
|
case 2:
|
|
|
|
return &v.unknownFields
|
|
|
|
default:
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
}
|
|
|
|
file_signrpc_signer_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} {
|
|
|
|
switch v := v.(*SharedKeyResponse); i {
|
|
|
|
case 0:
|
|
|
|
return &v.state
|
|
|
|
case 1:
|
|
|
|
return &v.sizeCache
|
|
|
|
case 2:
|
|
|
|
return &v.unknownFields
|
|
|
|
default:
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
type x struct{}
|
|
|
|
out := protoimpl.TypeBuilder{
|
|
|
|
File: protoimpl.DescBuilder{
|
|
|
|
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
|
|
|
RawDescriptor: file_signrpc_signer_proto_rawDesc,
|
|
|
|
NumEnums: 0,
|
|
|
|
NumMessages: 14,
|
|
|
|
NumExtensions: 0,
|
|
|
|
NumServices: 1,
|
|
|
|
},
|
|
|
|
GoTypes: file_signrpc_signer_proto_goTypes,
|
|
|
|
DependencyIndexes: file_signrpc_signer_proto_depIdxs,
|
|
|
|
MessageInfos: file_signrpc_signer_proto_msgTypes,
|
|
|
|
}.Build()
|
|
|
|
File_signrpc_signer_proto = out.File
|
|
|
|
file_signrpc_signer_proto_rawDesc = nil
|
|
|
|
file_signrpc_signer_proto_goTypes = nil
|
|
|
|
file_signrpc_signer_proto_depIdxs = nil
|
2019-05-15 16:07:30 +03:00
|
|
|
}
|
|
|
|
|
2018-10-23 03:30:02 +03:00
|
|
|
// Reference imports to suppress errors if they are not otherwise used.
|
|
|
|
var _ context.Context
|
2021-04-28 16:30:59 +03:00
|
|
|
var _ grpc.ClientConnInterface
|
2018-10-23 03:30:02 +03:00
|
|
|
|
|
|
|
// This is a compile-time assertion to ensure that this generated file
|
|
|
|
// is compatible with the grpc package it is being compiled against.
|
2021-04-28 16:30:59 +03:00
|
|
|
const _ = grpc.SupportPackageIsVersion6
|
2018-10-23 03:30:02 +03:00
|
|
|
|
2018-12-11 13:42:43 +03:00
|
|
|
// SignerClient is the client API for Signer service.
|
|
|
|
//
|
|
|
|
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
|
2018-10-23 03:30:02 +03:00
|
|
|
type SignerClient interface {
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2019-05-15 16:07:30 +03:00
|
|
|
//SignOutputRaw is a method that can be used to generated a signature for a
|
|
|
|
//set of inputs/outputs to a transaction. Each request specifies details
|
|
|
|
//concerning how the outputs should be signed, which keys they should be
|
|
|
|
//signed with, and also any optional tweaks. The return value is a fixed
|
|
|
|
//64-byte signature (the same format as we use on the wire in Lightning).
|
2018-10-23 03:30:02 +03:00
|
|
|
//
|
2019-05-15 16:07:30 +03:00
|
|
|
//If we are unable to sign using the specified keys, then an error will be
|
|
|
|
//returned.
|
2018-10-23 03:30:02 +03:00
|
|
|
SignOutputRaw(ctx context.Context, in *SignReq, opts ...grpc.CallOption) (*SignResp, error)
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2019-05-15 16:07:30 +03:00
|
|
|
//ComputeInputScript generates a complete InputIndex for the passed
|
|
|
|
//transaction with the signature as defined within the passed SignDescriptor.
|
|
|
|
//This method should be capable of generating the proper input script for
|
|
|
|
//both regular p2wkh output and p2wkh outputs nested within a regular p2sh
|
|
|
|
//output.
|
2018-11-29 07:08:00 +03:00
|
|
|
//
|
2019-05-15 16:07:30 +03:00
|
|
|
//Note that when using this method to sign inputs belonging to the wallet,
|
|
|
|
//the only items of the SignDescriptor that need to be populated are pkScript
|
|
|
|
//in the TxOut field, the value in that same field, and finally the input
|
|
|
|
//index.
|
2018-11-29 07:08:00 +03:00
|
|
|
ComputeInputScript(ctx context.Context, in *SignReq, opts ...grpc.CallOption) (*InputScriptResp, error)
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2019-12-10 11:48:49 +03:00
|
|
|
//SignMessage signs a message with the key specified in the key locator. The
|
2019-12-13 04:20:33 +03:00
|
|
|
//returned signature is fixed-size LN wire format encoded.
|
2019-12-10 11:48:49 +03:00
|
|
|
//
|
|
|
|
//The main difference to SignMessage in the main RPC is that a specific key is
|
|
|
|
//used to sign the message instead of the node identity private key.
|
|
|
|
SignMessage(ctx context.Context, in *SignMessageReq, opts ...grpc.CallOption) (*SignMessageResp, error)
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2019-12-10 11:48:49 +03:00
|
|
|
//VerifyMessage verifies a signature over a message using the public key
|
2019-12-13 04:20:33 +03:00
|
|
|
//provided. The signature must be fixed-size LN wire format encoded.
|
2019-12-10 11:48:49 +03:00
|
|
|
//
|
|
|
|
//The main difference to VerifyMessage in the main RPC is that the public key
|
|
|
|
//used to sign the message does not have to be a node known to the network.
|
|
|
|
VerifyMessage(ctx context.Context, in *VerifyMessageReq, opts ...grpc.CallOption) (*VerifyMessageResp, error)
|
2019-11-28 12:58:51 +03:00
|
|
|
//
|
|
|
|
//DeriveSharedKey returns a shared secret key by performing Diffie-Hellman key
|
|
|
|
//derivation between the ephemeral public key in the request and the node's
|
2020-07-28 00:39:12 +03:00
|
|
|
//key specified in the key_desc parameter. Either a key locator or a raw
|
|
|
|
//public key is expected in the key_desc, if neither is supplied, defaults to
|
|
|
|
//the node's identity private key:
|
2020-01-06 16:53:24 +03:00
|
|
|
//P_shared = privKeyNode * ephemeralPubkey
|
2019-11-28 12:58:51 +03:00
|
|
|
//The resulting shared public key is serialized in the compressed format and
|
|
|
|
//hashed with sha256, resulting in the final key length of 256bit.
|
|
|
|
DeriveSharedKey(ctx context.Context, in *SharedKeyRequest, opts ...grpc.CallOption) (*SharedKeyResponse, error)
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
type signerClient struct {
|
2021-04-28 16:30:59 +03:00
|
|
|
cc grpc.ClientConnInterface
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func NewSignerClient(cc grpc.ClientConnInterface) SignerClient {
|
2018-10-23 03:30:02 +03:00
|
|
|
return &signerClient{cc}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (c *signerClient) SignOutputRaw(ctx context.Context, in *SignReq, opts ...grpc.CallOption) (*SignResp, error) {
|
|
|
|
out := new(SignResp)
|
2018-12-11 13:42:43 +03:00
|
|
|
err := c.cc.Invoke(ctx, "/signrpc.Signer/SignOutputRaw", in, out, opts...)
|
2018-10-23 03:30:02 +03:00
|
|
|
if err != nil {
|
|
|
|
return nil, err
|
|
|
|
}
|
|
|
|
return out, nil
|
|
|
|
}
|
|
|
|
|
2018-11-29 07:08:00 +03:00
|
|
|
func (c *signerClient) ComputeInputScript(ctx context.Context, in *SignReq, opts ...grpc.CallOption) (*InputScriptResp, error) {
|
|
|
|
out := new(InputScriptResp)
|
2018-12-11 13:42:43 +03:00
|
|
|
err := c.cc.Invoke(ctx, "/signrpc.Signer/ComputeInputScript", in, out, opts...)
|
2018-11-29 07:08:00 +03:00
|
|
|
if err != nil {
|
|
|
|
return nil, err
|
|
|
|
}
|
|
|
|
return out, nil
|
|
|
|
}
|
|
|
|
|
2019-12-10 11:48:49 +03:00
|
|
|
func (c *signerClient) SignMessage(ctx context.Context, in *SignMessageReq, opts ...grpc.CallOption) (*SignMessageResp, error) {
|
|
|
|
out := new(SignMessageResp)
|
|
|
|
err := c.cc.Invoke(ctx, "/signrpc.Signer/SignMessage", in, out, opts...)
|
|
|
|
if err != nil {
|
|
|
|
return nil, err
|
|
|
|
}
|
|
|
|
return out, nil
|
|
|
|
}
|
|
|
|
|
|
|
|
func (c *signerClient) VerifyMessage(ctx context.Context, in *VerifyMessageReq, opts ...grpc.CallOption) (*VerifyMessageResp, error) {
|
|
|
|
out := new(VerifyMessageResp)
|
|
|
|
err := c.cc.Invoke(ctx, "/signrpc.Signer/VerifyMessage", in, out, opts...)
|
|
|
|
if err != nil {
|
|
|
|
return nil, err
|
|
|
|
}
|
|
|
|
return out, nil
|
|
|
|
}
|
|
|
|
|
2019-11-28 12:58:51 +03:00
|
|
|
func (c *signerClient) DeriveSharedKey(ctx context.Context, in *SharedKeyRequest, opts ...grpc.CallOption) (*SharedKeyResponse, error) {
|
|
|
|
out := new(SharedKeyResponse)
|
|
|
|
err := c.cc.Invoke(ctx, "/signrpc.Signer/DeriveSharedKey", in, out, opts...)
|
|
|
|
if err != nil {
|
|
|
|
return nil, err
|
|
|
|
}
|
|
|
|
return out, nil
|
|
|
|
}
|
|
|
|
|
2018-12-11 13:42:43 +03:00
|
|
|
// SignerServer is the server API for Signer service.
|
2018-10-23 03:30:02 +03:00
|
|
|
type SignerServer interface {
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2019-05-15 16:07:30 +03:00
|
|
|
//SignOutputRaw is a method that can be used to generated a signature for a
|
|
|
|
//set of inputs/outputs to a transaction. Each request specifies details
|
|
|
|
//concerning how the outputs should be signed, which keys they should be
|
|
|
|
//signed with, and also any optional tweaks. The return value is a fixed
|
|
|
|
//64-byte signature (the same format as we use on the wire in Lightning).
|
2018-10-23 03:30:02 +03:00
|
|
|
//
|
2019-05-15 16:07:30 +03:00
|
|
|
//If we are unable to sign using the specified keys, then an error will be
|
|
|
|
//returned.
|
2018-10-23 03:30:02 +03:00
|
|
|
SignOutputRaw(context.Context, *SignReq) (*SignResp, error)
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2019-05-15 16:07:30 +03:00
|
|
|
//ComputeInputScript generates a complete InputIndex for the passed
|
|
|
|
//transaction with the signature as defined within the passed SignDescriptor.
|
|
|
|
//This method should be capable of generating the proper input script for
|
|
|
|
//both regular p2wkh output and p2wkh outputs nested within a regular p2sh
|
|
|
|
//output.
|
2018-11-29 07:08:00 +03:00
|
|
|
//
|
2019-05-15 16:07:30 +03:00
|
|
|
//Note that when using this method to sign inputs belonging to the wallet,
|
|
|
|
//the only items of the SignDescriptor that need to be populated are pkScript
|
|
|
|
//in the TxOut field, the value in that same field, and finally the input
|
|
|
|
//index.
|
2018-11-29 07:08:00 +03:00
|
|
|
ComputeInputScript(context.Context, *SignReq) (*InputScriptResp, error)
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2019-12-10 11:48:49 +03:00
|
|
|
//SignMessage signs a message with the key specified in the key locator. The
|
2019-12-13 04:20:33 +03:00
|
|
|
//returned signature is fixed-size LN wire format encoded.
|
2019-12-10 11:48:49 +03:00
|
|
|
//
|
|
|
|
//The main difference to SignMessage in the main RPC is that a specific key is
|
|
|
|
//used to sign the message instead of the node identity private key.
|
|
|
|
SignMessage(context.Context, *SignMessageReq) (*SignMessageResp, error)
|
2020-05-06 17:51:14 +03:00
|
|
|
//
|
2019-12-10 11:48:49 +03:00
|
|
|
//VerifyMessage verifies a signature over a message using the public key
|
2019-12-13 04:20:33 +03:00
|
|
|
//provided. The signature must be fixed-size LN wire format encoded.
|
2019-12-10 11:48:49 +03:00
|
|
|
//
|
|
|
|
//The main difference to VerifyMessage in the main RPC is that the public key
|
|
|
|
//used to sign the message does not have to be a node known to the network.
|
|
|
|
VerifyMessage(context.Context, *VerifyMessageReq) (*VerifyMessageResp, error)
|
2019-11-28 12:58:51 +03:00
|
|
|
//
|
|
|
|
//DeriveSharedKey returns a shared secret key by performing Diffie-Hellman key
|
|
|
|
//derivation between the ephemeral public key in the request and the node's
|
2020-07-28 00:39:12 +03:00
|
|
|
//key specified in the key_desc parameter. Either a key locator or a raw
|
|
|
|
//public key is expected in the key_desc, if neither is supplied, defaults to
|
|
|
|
//the node's identity private key:
|
2020-01-06 16:53:24 +03:00
|
|
|
//P_shared = privKeyNode * ephemeralPubkey
|
2019-11-28 12:58:51 +03:00
|
|
|
//The resulting shared public key is serialized in the compressed format and
|
|
|
|
//hashed with sha256, resulting in the final key length of 256bit.
|
|
|
|
DeriveSharedKey(context.Context, *SharedKeyRequest) (*SharedKeyResponse, error)
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|
|
|
|
|
2020-05-28 14:07:31 +03:00
|
|
|
// UnimplementedSignerServer can be embedded to have forward compatible implementations.
|
|
|
|
type UnimplementedSignerServer struct {
|
|
|
|
}
|
|
|
|
|
2021-04-28 16:30:59 +03:00
|
|
|
func (*UnimplementedSignerServer) SignOutputRaw(context.Context, *SignReq) (*SignResp, error) {
|
2020-05-28 14:07:31 +03:00
|
|
|
return nil, status.Errorf(codes.Unimplemented, "method SignOutputRaw not implemented")
|
|
|
|
}
|
2021-04-28 16:30:59 +03:00
|
|
|
func (*UnimplementedSignerServer) ComputeInputScript(context.Context, *SignReq) (*InputScriptResp, error) {
|
2020-05-28 14:07:31 +03:00
|
|
|
return nil, status.Errorf(codes.Unimplemented, "method ComputeInputScript not implemented")
|
|
|
|
}
|
2021-04-28 16:30:59 +03:00
|
|
|
func (*UnimplementedSignerServer) SignMessage(context.Context, *SignMessageReq) (*SignMessageResp, error) {
|
2020-05-28 14:07:31 +03:00
|
|
|
return nil, status.Errorf(codes.Unimplemented, "method SignMessage not implemented")
|
|
|
|
}
|
2021-04-28 16:30:59 +03:00
|
|
|
func (*UnimplementedSignerServer) VerifyMessage(context.Context, *VerifyMessageReq) (*VerifyMessageResp, error) {
|
2020-05-28 14:07:31 +03:00
|
|
|
return nil, status.Errorf(codes.Unimplemented, "method VerifyMessage not implemented")
|
|
|
|
}
|
2021-04-28 16:30:59 +03:00
|
|
|
func (*UnimplementedSignerServer) DeriveSharedKey(context.Context, *SharedKeyRequest) (*SharedKeyResponse, error) {
|
2020-05-28 14:07:31 +03:00
|
|
|
return nil, status.Errorf(codes.Unimplemented, "method DeriveSharedKey not implemented")
|
|
|
|
}
|
|
|
|
|
2018-10-23 03:30:02 +03:00
|
|
|
func RegisterSignerServer(s *grpc.Server, srv SignerServer) {
|
|
|
|
s.RegisterService(&_Signer_serviceDesc, srv)
|
|
|
|
}
|
|
|
|
|
|
|
|
func _Signer_SignOutputRaw_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
|
|
|
in := new(SignReq)
|
|
|
|
if err := dec(in); err != nil {
|
|
|
|
return nil, err
|
|
|
|
}
|
|
|
|
if interceptor == nil {
|
|
|
|
return srv.(SignerServer).SignOutputRaw(ctx, in)
|
|
|
|
}
|
|
|
|
info := &grpc.UnaryServerInfo{
|
|
|
|
Server: srv,
|
|
|
|
FullMethod: "/signrpc.Signer/SignOutputRaw",
|
|
|
|
}
|
|
|
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
|
|
|
return srv.(SignerServer).SignOutputRaw(ctx, req.(*SignReq))
|
|
|
|
}
|
|
|
|
return interceptor(ctx, in, info, handler)
|
|
|
|
}
|
|
|
|
|
2018-11-29 07:08:00 +03:00
|
|
|
func _Signer_ComputeInputScript_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
|
|
|
in := new(SignReq)
|
|
|
|
if err := dec(in); err != nil {
|
|
|
|
return nil, err
|
|
|
|
}
|
|
|
|
if interceptor == nil {
|
|
|
|
return srv.(SignerServer).ComputeInputScript(ctx, in)
|
|
|
|
}
|
|
|
|
info := &grpc.UnaryServerInfo{
|
|
|
|
Server: srv,
|
|
|
|
FullMethod: "/signrpc.Signer/ComputeInputScript",
|
|
|
|
}
|
|
|
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
|
|
|
return srv.(SignerServer).ComputeInputScript(ctx, req.(*SignReq))
|
|
|
|
}
|
|
|
|
return interceptor(ctx, in, info, handler)
|
|
|
|
}
|
|
|
|
|
2019-12-10 11:48:49 +03:00
|
|
|
func _Signer_SignMessage_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
|
|
|
in := new(SignMessageReq)
|
|
|
|
if err := dec(in); err != nil {
|
|
|
|
return nil, err
|
|
|
|
}
|
|
|
|
if interceptor == nil {
|
|
|
|
return srv.(SignerServer).SignMessage(ctx, in)
|
|
|
|
}
|
|
|
|
info := &grpc.UnaryServerInfo{
|
|
|
|
Server: srv,
|
|
|
|
FullMethod: "/signrpc.Signer/SignMessage",
|
|
|
|
}
|
|
|
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
|
|
|
return srv.(SignerServer).SignMessage(ctx, req.(*SignMessageReq))
|
|
|
|
}
|
|
|
|
return interceptor(ctx, in, info, handler)
|
|
|
|
}
|
|
|
|
|
|
|
|
func _Signer_VerifyMessage_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
|
|
|
in := new(VerifyMessageReq)
|
|
|
|
if err := dec(in); err != nil {
|
|
|
|
return nil, err
|
|
|
|
}
|
|
|
|
if interceptor == nil {
|
|
|
|
return srv.(SignerServer).VerifyMessage(ctx, in)
|
|
|
|
}
|
|
|
|
info := &grpc.UnaryServerInfo{
|
|
|
|
Server: srv,
|
|
|
|
FullMethod: "/signrpc.Signer/VerifyMessage",
|
|
|
|
}
|
|
|
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
|
|
|
return srv.(SignerServer).VerifyMessage(ctx, req.(*VerifyMessageReq))
|
|
|
|
}
|
|
|
|
return interceptor(ctx, in, info, handler)
|
|
|
|
}
|
|
|
|
|
2019-11-28 12:58:51 +03:00
|
|
|
func _Signer_DeriveSharedKey_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
|
|
|
in := new(SharedKeyRequest)
|
|
|
|
if err := dec(in); err != nil {
|
|
|
|
return nil, err
|
|
|
|
}
|
|
|
|
if interceptor == nil {
|
|
|
|
return srv.(SignerServer).DeriveSharedKey(ctx, in)
|
|
|
|
}
|
|
|
|
info := &grpc.UnaryServerInfo{
|
|
|
|
Server: srv,
|
|
|
|
FullMethod: "/signrpc.Signer/DeriveSharedKey",
|
|
|
|
}
|
|
|
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
|
|
|
return srv.(SignerServer).DeriveSharedKey(ctx, req.(*SharedKeyRequest))
|
|
|
|
}
|
|
|
|
return interceptor(ctx, in, info, handler)
|
|
|
|
}
|
|
|
|
|
2018-10-23 03:30:02 +03:00
|
|
|
var _Signer_serviceDesc = grpc.ServiceDesc{
|
|
|
|
ServiceName: "signrpc.Signer",
|
|
|
|
HandlerType: (*SignerServer)(nil),
|
|
|
|
Methods: []grpc.MethodDesc{
|
|
|
|
{
|
|
|
|
MethodName: "SignOutputRaw",
|
|
|
|
Handler: _Signer_SignOutputRaw_Handler,
|
|
|
|
},
|
2018-11-29 07:08:00 +03:00
|
|
|
{
|
|
|
|
MethodName: "ComputeInputScript",
|
|
|
|
Handler: _Signer_ComputeInputScript_Handler,
|
|
|
|
},
|
2019-12-10 11:48:49 +03:00
|
|
|
{
|
|
|
|
MethodName: "SignMessage",
|
|
|
|
Handler: _Signer_SignMessage_Handler,
|
|
|
|
},
|
|
|
|
{
|
|
|
|
MethodName: "VerifyMessage",
|
|
|
|
Handler: _Signer_VerifyMessage_Handler,
|
|
|
|
},
|
2019-11-28 12:58:51 +03:00
|
|
|
{
|
|
|
|
MethodName: "DeriveSharedKey",
|
|
|
|
Handler: _Signer_DeriveSharedKey_Handler,
|
|
|
|
},
|
2018-10-23 03:30:02 +03:00
|
|
|
},
|
|
|
|
Streams: []grpc.StreamDesc{},
|
2018-10-31 07:14:48 +03:00
|
|
|
Metadata: "signrpc/signer.proto",
|
2018-10-23 03:30:02 +03:00
|
|
|
}
|