Skip to content

Commit d5eff47

Browse files
authored
Merge pull request #222 from lightninglabs/musig2-local-nonce
signer: option to add the local nonce to the MuSig2 session
2 parents 7835d6e + 57d6e5d commit d5eff47

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

signer_client.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -579,6 +579,13 @@ func MuSig2TaprootTweakOpt(scriptRoot []byte,
579579
}
580580
}
581581

582+
// MuSig2LocalNonceOpt adds the local secret nonce to the musig session request.
583+
func MuSig2LocalNonceOpt(nonce [musig2.SecNonceSize]byte) MuSig2SessionOpts {
584+
return func(s *signrpc.MuSig2SessionRequest) {
585+
s.PregeneratedLocalNonce = nonce[:]
586+
}
587+
}
588+
582589
// marshallMuSig2Version translates the passed input.MuSig2Version value to
583590
// signrpc.MuSig2Version.
584591
func marshallMuSig2Version(version input.MuSig2Version) (

0 commit comments

Comments
 (0)