Skip to content

encodePeer in client.js doesn't check if port is our of range #175

Open
@bjackson

Description

@bjackson

encodePeer doesn't check for out of bounds values before writing them to a Buffer, which can cause an error to be thrown.

I would submit a PR, but I'm not sure what the behavior should be when a peer with a port that is outside the range is discovered.

https://github.com/webtorrent/bittorrent-dht/blob/master/client.js#L618

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions