Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions signer_client.go
Original file line number Diff line number Diff line change
Expand Up @@ -502,6 +502,12 @@ func (s *signerClient) VerifyMessage(ctx context.Context, msg, sig []byte,
opt(rpcIn)
}

// If the signature is a Schnorr signature, we need to set the public
// key as the 32-byte x-only key, as mentioned in the RPC docs.
if rpcIn.IsSchnorrSig {
rpcIn.Pubkey = pubkey[1:]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could also check for the len(pubkey) here to avoid a potential panic?

Copy link
Member

@ellemouton ellemouton Jun 2, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i dont think it can panic. The param is [33]byte and so is guaranteed to have 33 bytes

}

rpcCtx = s.signerMac.WithMacaroonAuth(rpcCtx)
resp, err := s.client.VerifyMessage(rpcCtx, rpcIn)
if err != nil {
Expand Down