lnrpc: re-compile protos w/ Go 1.19

This commit is contained in:
Olaoluwa Osuntokun committed 2022-08-24 11:43:00 -05:00
1 parent 65a5eeb24e
commit b3998ddb5c
24 files changed
+2773 -3481

No files matched your search

+158 -180
View File
@@ -18,116 +18,105 @@ const _ = grpc.SupportPackageIsVersion7
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
type SignerClient interface {
// 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).
//
//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).
//
//If we are unable to sign using the specified keys, then an error will be
//returned.
// If we are unable to sign using the specified keys, then an error will be
// returned.
SignOutputRaw(ctx context.Context, in *SignReq, opts ...grpc.CallOption) (*SignResp, error)
// 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/p2tr outputs and p2wkh outputs nested within a regular p2sh
// output.
//
//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/p2tr outputs and p2wkh outputs nested within a regular p2sh
//output.
//
//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.
// 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.
ComputeInputScript(ctx context.Context, in *SignReq, opts ...grpc.CallOption) (*InputScriptResp, error)
// SignMessage signs a message with the key specified in the key locator. The
// returned signature is fixed-size LN wire format encoded.
//
//SignMessage signs a message with the key specified in the key locator. The
//returned signature is fixed-size LN wire format encoded.
//
//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.
// 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)
// VerifyMessage verifies a signature over a message using the public key
// provided. The signature must be fixed-size LN wire format encoded.
//
//VerifyMessage verifies a signature over a message using the public key
//provided. The signature must be fixed-size LN wire format encoded.
//
//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.
// 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)
//
//DeriveSharedKey returns a shared secret key by performing Diffie-Hellman key
//derivation between the ephemeral public key in the request and the node's
//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:
//P_shared = privKeyNode * ephemeralPubkey
//The resulting shared public key is serialized in the compressed format and
//hashed with sha256, resulting in the final key length of 256bit.
// DeriveSharedKey returns a shared secret key by performing Diffie-Hellman key
// derivation between the ephemeral public key in the request and the node's
// 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:
// P_shared = privKeyNode * ephemeralPubkey
// 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)
// MuSig2CombineKeys (experimental!) is a stateless helper RPC that can be used
// to calculate the combined MuSig2 public key from a list of all participating
// signers' public keys. This RPC is completely stateless and deterministic and
// does not create any signing session. It can be used to determine the Taproot
// public key that should be put in an on-chain output once all public keys are
// known. A signing session is only needed later when that output should be
// _spent_ again.
//
//MuSig2CombineKeys (experimental!) is a stateless helper RPC that can be used
//to calculate the combined MuSig2 public key from a list of all participating
//signers' public keys. This RPC is completely stateless and deterministic and
//does not create any signing session. It can be used to determine the Taproot
//public key that should be put in an on-chain output once all public keys are
//known. A signing session is only needed later when that output should be
//_spent_ again.
//
//NOTE: The MuSig2 BIP is not final yet and therefore this API must be
//considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
//releases. Backward compatibility is not guaranteed!
// NOTE: The MuSig2 BIP is not final yet and therefore this API must be
// considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
// releases. Backward compatibility is not guaranteed!
MuSig2CombineKeys(ctx context.Context, in *MuSig2CombineKeysRequest, opts ...grpc.CallOption) (*MuSig2CombineKeysResponse, error)
// MuSig2CreateSession (experimental!) creates a new MuSig2 signing session
// using the local key identified by the key locator. The complete list of all
// public keys of all signing parties must be provided, including the public
// key of the local signing key. If nonces of other parties are already known,
// they can be submitted as well to reduce the number of RPC calls necessary
// later on.
//
//MuSig2CreateSession (experimental!) creates a new MuSig2 signing session
//using the local key identified by the key locator. The complete list of all
//public keys of all signing parties must be provided, including the public
//key of the local signing key. If nonces of other parties are already known,
//they can be submitted as well to reduce the number of RPC calls necessary
//later on.
//
//NOTE: The MuSig2 BIP is not final yet and therefore this API must be
//considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
//releases. Backward compatibility is not guaranteed!
// NOTE: The MuSig2 BIP is not final yet and therefore this API must be
// considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
// releases. Backward compatibility is not guaranteed!
MuSig2CreateSession(ctx context.Context, in *MuSig2SessionRequest, opts ...grpc.CallOption) (*MuSig2SessionResponse, error)
// MuSig2RegisterNonces (experimental!) registers one or more public nonces of
// other signing participants for a session identified by its ID. This RPC can
// be called multiple times until all nonces are registered.
//
//MuSig2RegisterNonces (experimental!) registers one or more public nonces of
//other signing participants for a session identified by its ID. This RPC can
//be called multiple times until all nonces are registered.
//
//NOTE: The MuSig2 BIP is not final yet and therefore this API must be
//considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
//releases. Backward compatibility is not guaranteed!
// NOTE: The MuSig2 BIP is not final yet and therefore this API must be
// considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
// releases. Backward compatibility is not guaranteed!
MuSig2RegisterNonces(ctx context.Context, in *MuSig2RegisterNoncesRequest, opts ...grpc.CallOption) (*MuSig2RegisterNoncesResponse, error)
// MuSig2Sign (experimental!) creates a partial signature using the local
// signing key that was specified when the session was created. This can only
// be called when all public nonces of all participants are known and have been
// registered with the session. If this node isn't responsible for combining
// all the partial signatures, then the cleanup flag should be set, indicating
// that the session can be removed from memory once the signature was produced.
//
//MuSig2Sign (experimental!) creates a partial signature using the local
//signing key that was specified when the session was created. This can only
//be called when all public nonces of all participants are known and have been
//registered with the session. If this node isn't responsible for combining
//all the partial signatures, then the cleanup flag should be set, indicating
//that the session can be removed from memory once the signature was produced.
//
//NOTE: The MuSig2 BIP is not final yet and therefore this API must be
//considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
//releases. Backward compatibility is not guaranteed!
// NOTE: The MuSig2 BIP is not final yet and therefore this API must be
// considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
// releases. Backward compatibility is not guaranteed!
MuSig2Sign(ctx context.Context, in *MuSig2SignRequest, opts ...grpc.CallOption) (*MuSig2SignResponse, error)
// MuSig2CombineSig (experimental!) combines the given partial signature(s)
// with the local one, if it already exists. Once a partial signature of all
// participants is registered, the final signature will be combined and
// returned.
//
//MuSig2CombineSig (experimental!) combines the given partial signature(s)
//with the local one, if it already exists. Once a partial signature of all
//participants is registered, the final signature will be combined and
//returned.
//
//NOTE: The MuSig2 BIP is not final yet and therefore this API must be
//considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
//releases. Backward compatibility is not guaranteed!
// NOTE: The MuSig2 BIP is not final yet and therefore this API must be
// considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
// releases. Backward compatibility is not guaranteed!
MuSig2CombineSig(ctx context.Context, in *MuSig2CombineSigRequest, opts ...grpc.CallOption) (*MuSig2CombineSigResponse, error)
// MuSig2Cleanup (experimental!) allows a caller to clean up a session early in
// cases where it's obvious that the signing session won't succeed and the
// resources can be released.
//
//MuSig2Cleanup (experimental!) allows a caller to clean up a session early in
//cases where it's obvious that the signing session won't succeed and the
//resources can be released.
//
//NOTE: The MuSig2 BIP is not final yet and therefore this API must be
//considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
//releases. Backward compatibility is not guaranteed!
// NOTE: The MuSig2 BIP is not final yet and therefore this API must be
// considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
// releases. Backward compatibility is not guaranteed!
MuSig2Cleanup(ctx context.Context, in *MuSig2CleanupRequest, opts ...grpc.CallOption) (*MuSig2CleanupResponse, error)
}
@@ -242,116 +231,105 @@ func (c *signerClient) MuSig2Cleanup(ctx context.Context, in *MuSig2CleanupReque
// All implementations must embed UnimplementedSignerServer
// for forward compatibility
type SignerServer interface {
// 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).
//
//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).
//
//If we are unable to sign using the specified keys, then an error will be
//returned.
// If we are unable to sign using the specified keys, then an error will be
// returned.
SignOutputRaw(context.Context, *SignReq) (*SignResp, error)
// 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/p2tr outputs and p2wkh outputs nested within a regular p2sh
// output.
//
//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/p2tr outputs and p2wkh outputs nested within a regular p2sh
//output.
//
//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.
// 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.
ComputeInputScript(context.Context, *SignReq) (*InputScriptResp, error)
// SignMessage signs a message with the key specified in the key locator. The
// returned signature is fixed-size LN wire format encoded.
//
//SignMessage signs a message with the key specified in the key locator. The
//returned signature is fixed-size LN wire format encoded.
//
//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.
// 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)
// VerifyMessage verifies a signature over a message using the public key
// provided. The signature must be fixed-size LN wire format encoded.
//
//VerifyMessage verifies a signature over a message using the public key
//provided. The signature must be fixed-size LN wire format encoded.
//
//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.
// 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)
//
//DeriveSharedKey returns a shared secret key by performing Diffie-Hellman key
//derivation between the ephemeral public key in the request and the node's
//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:
//P_shared = privKeyNode * ephemeralPubkey
//The resulting shared public key is serialized in the compressed format and
//hashed with sha256, resulting in the final key length of 256bit.
// DeriveSharedKey returns a shared secret key by performing Diffie-Hellman key
// derivation between the ephemeral public key in the request and the node's
// 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:
// P_shared = privKeyNode * ephemeralPubkey
// 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)
// MuSig2CombineKeys (experimental!) is a stateless helper RPC that can be used
// to calculate the combined MuSig2 public key from a list of all participating
// signers' public keys. This RPC is completely stateless and deterministic and
// does not create any signing session. It can be used to determine the Taproot
// public key that should be put in an on-chain output once all public keys are
// known. A signing session is only needed later when that output should be
// _spent_ again.
//
//MuSig2CombineKeys (experimental!) is a stateless helper RPC that can be used
//to calculate the combined MuSig2 public key from a list of all participating
//signers' public keys. This RPC is completely stateless and deterministic and
//does not create any signing session. It can be used to determine the Taproot
//public key that should be put in an on-chain output once all public keys are
//known. A signing session is only needed later when that output should be
//_spent_ again.
//
//NOTE: The MuSig2 BIP is not final yet and therefore this API must be
//considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
//releases. Backward compatibility is not guaranteed!
// NOTE: The MuSig2 BIP is not final yet and therefore this API must be
// considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
// releases. Backward compatibility is not guaranteed!
MuSig2CombineKeys(context.Context, *MuSig2CombineKeysRequest) (*MuSig2CombineKeysResponse, error)
// MuSig2CreateSession (experimental!) creates a new MuSig2 signing session
// using the local key identified by the key locator. The complete list of all
// public keys of all signing parties must be provided, including the public
// key of the local signing key. If nonces of other parties are already known,
// they can be submitted as well to reduce the number of RPC calls necessary
// later on.
//
//MuSig2CreateSession (experimental!) creates a new MuSig2 signing session
//using the local key identified by the key locator. The complete list of all
//public keys of all signing parties must be provided, including the public
//key of the local signing key. If nonces of other parties are already known,
//they can be submitted as well to reduce the number of RPC calls necessary
//later on.
//
//NOTE: The MuSig2 BIP is not final yet and therefore this API must be
//considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
//releases. Backward compatibility is not guaranteed!
// NOTE: The MuSig2 BIP is not final yet and therefore this API must be
// considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
// releases. Backward compatibility is not guaranteed!
MuSig2CreateSession(context.Context, *MuSig2SessionRequest) (*MuSig2SessionResponse, error)
// MuSig2RegisterNonces (experimental!) registers one or more public nonces of
// other signing participants for a session identified by its ID. This RPC can
// be called multiple times until all nonces are registered.
//
//MuSig2RegisterNonces (experimental!) registers one or more public nonces of
//other signing participants for a session identified by its ID. This RPC can
//be called multiple times until all nonces are registered.
//
//NOTE: The MuSig2 BIP is not final yet and therefore this API must be
//considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
//releases. Backward compatibility is not guaranteed!
// NOTE: The MuSig2 BIP is not final yet and therefore this API must be
// considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
// releases. Backward compatibility is not guaranteed!
MuSig2RegisterNonces(context.Context, *MuSig2RegisterNoncesRequest) (*MuSig2RegisterNoncesResponse, error)
// MuSig2Sign (experimental!) creates a partial signature using the local
// signing key that was specified when the session was created. This can only
// be called when all public nonces of all participants are known and have been
// registered with the session. If this node isn't responsible for combining
// all the partial signatures, then the cleanup flag should be set, indicating
// that the session can be removed from memory once the signature was produced.
//
//MuSig2Sign (experimental!) creates a partial signature using the local
//signing key that was specified when the session was created. This can only
//be called when all public nonces of all participants are known and have been
//registered with the session. If this node isn't responsible for combining
//all the partial signatures, then the cleanup flag should be set, indicating
//that the session can be removed from memory once the signature was produced.
//
//NOTE: The MuSig2 BIP is not final yet and therefore this API must be
//considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
//releases. Backward compatibility is not guaranteed!
// NOTE: The MuSig2 BIP is not final yet and therefore this API must be
// considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
// releases. Backward compatibility is not guaranteed!
MuSig2Sign(context.Context, *MuSig2SignRequest) (*MuSig2SignResponse, error)
// MuSig2CombineSig (experimental!) combines the given partial signature(s)
// with the local one, if it already exists. Once a partial signature of all
// participants is registered, the final signature will be combined and
// returned.
//
//MuSig2CombineSig (experimental!) combines the given partial signature(s)
//with the local one, if it already exists. Once a partial signature of all
//participants is registered, the final signature will be combined and
//returned.
//
//NOTE: The MuSig2 BIP is not final yet and therefore this API must be
//considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
//releases. Backward compatibility is not guaranteed!
// NOTE: The MuSig2 BIP is not final yet and therefore this API must be
// considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
// releases. Backward compatibility is not guaranteed!
MuSig2CombineSig(context.Context, *MuSig2CombineSigRequest) (*MuSig2CombineSigResponse, error)
// MuSig2Cleanup (experimental!) allows a caller to clean up a session early in
// cases where it's obvious that the signing session won't succeed and the
// resources can be released.
//
//MuSig2Cleanup (experimental!) allows a caller to clean up a session early in
//cases where it's obvious that the signing session won't succeed and the
//resources can be released.
//
//NOTE: The MuSig2 BIP is not final yet and therefore this API must be
//considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
//releases. Backward compatibility is not guaranteed!
// NOTE: The MuSig2 BIP is not final yet and therefore this API must be
// considered to be HIGHLY EXPERIMENTAL and subject to change in upcoming
// releases. Backward compatibility is not guaranteed!
MuSig2Cleanup(context.Context, *MuSig2CleanupRequest) (*MuSig2CleanupResponse, error)
mustEmbedUnimplementedSignerServer()
}