Skip to content

multiple ports #33

@executionByFork

Description

@executionByFork

SNMP uses ports 161 and 162 as standard. This tool only attempts to scan port 161 by default. There is a -p option but this only takes one port. The code strtol(optarg, NULL, 10) == 0 will take the first number it finds in the string and set as the port, then drop everything else as soon as a bad character is encountered.

As such, -p161,162 will run, but only scan port 161. This is confusing and unexpected behavior given that the command runs without warning or error. The current code only ever errors out if -p begins with a non-numeric character.

Suggestion: Implement functionality for multiple ports to be scanned from one program invocation. Allow the tool to take 161,162 and know to scan both ports 161 and 162. Additionally, scan both 161 and 162 by default

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