Skip to content

Commit a633313

Browse files
committed
fix: gosec incorrectly warns about accessing signature[64]
1 parent f805900 commit a633313

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

internal/utilities/siwe/parser.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -219,8 +219,9 @@ func (m *SIWEMessage) VerifySignature(signatureHex string) bool {
219219
copy(signature, sig)
220220

221221
// Normalize V if needed
222+
// #nosec G602
222223
if signature[64] >= 27 {
223-
signature[64] -= 27
224+
signature[64] -= 27 // #nosec G602
224225
}
225226

226227
hash := accounts.TextHash([]byte(m.Raw))

0 commit comments

Comments
 (0)