Skip to content

Commit

Permalink
Add support for Intent sessions built on secp256r1 - remove prefix
Browse files Browse the repository at this point in the history
  • Loading branch information
marino39 committed Feb 1, 2024
1 parent fc0f871 commit cee69e1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion intents/intent.go
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ func (intent *Intent) IsValid() bool {
}

func (intent *Intent) isValidSECP256R1Session(session string, signature string) bool {
return strings.HasPrefix(session, "r1:") && strings.HasPrefix(signature, "r1:")
return len(session) == 65 && len(signature) == 64
}

func (intent *Intent) isValidSignature(session string, signature string) bool {
Expand Down

0 comments on commit cee69e1

Please sign in to comment.