NAME
Net::Scan::SNMP - scan devices to verify SNMP community
SYNOPSIS
use Net::Scan::SNMP;
my $host = $ARGV[0];
my $scan = Net::Scan::SNMP->new({
host => $host,
timeout => 5
});
my $results = $scan->scan;
print "$host $results\n";
DESCRIPTION
This module permit to scan devices to verify SNMP community.
METHODS
new
The constructor. Given a host returns a Net::Scan::SNMP object:
my $scan = Net::Scan::SNMP->new({
host => '127.0.0.1',
port => 80,
protocol => udp,
snmp_version => 1,
community => 'public,
timeout => 5,
retries => 2
});
Optionally, you can also specify :
- port
-
Remote port. Default is 80;
- protocol
-
Set the default Transport Domain. Default is 8 seconds;
- snmp_version
-
Set the SNMP version. Default is 1.
- community
-
Set the SNMP community. Defaults is 'public'.
- timeout
-
Default is 8 seconds;
- retries
-
Set or get the current retry count for the object. Default is 2.
scan
Scan the target.
$scan->scan;
SEE ALSO
AUTHOR
Matteo Cantoni, <mcantoni@cpan.org>
COPYRIGHT AND LICENSE
You may distribute this module under the terms of the Artistic license. See Copying file in the source distribution archive.
Copyright (c) 2006, Matteo Cantoni