Skip to content

Commit

Permalink
chore: ignore arbitrary data stored in multiaddrs enr key (#2853)
Browse files Browse the repository at this point in the history
  • Loading branch information
richard-ramos authored Jun 27, 2024
1 parent 7205f95 commit 76d5b26
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion waku/waku_enr/multiaddr.nim
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,8 @@ func decodeMultiaddrs(buffer: seq[byte]): EnrResult[seq[MultiAddress]] =
return err("malformed multiaddr field: invalid length")

let addrRaw = ?readBytes(buffer, addrLen.int, pos)
let address = MultiAddress.init(addrRaw).get()
let address = MultiAddress.init(addrRaw).valueOr:
continue # Not a valid multiaddress

multiaddrs.add(address)

Expand Down

0 comments on commit 76d5b26

Please sign in to comment.