Rapid7::NeXpose::API - Communicate with NeXpose via XML NeXpose API v1.1
Version 0.03
This is Perl interface for communication with NeXpose scanner over API v1.1. You can start, stop, pause and resume scan. Watch progress and status of scan, download report, etc.
Currently you can only start scan, list sites and delete site.
use Rapid7::NeXpose::API; my $n = Rapid7::NeXpose::API->new( url=>'https://localhost:3780',password=>'test'); my $sl = $n->sitelist(); print "Starting scan for first site found: "; printf "%s with ID: %s\n", $sl->[0]->{'name'}, $sl->[0]->{'id'}; $n->sitescan($sl->[0]->{'id'});
This CPAN module uses LWP for communicating with NeXpose over its API via https. Therefore, make sure that you have Net::SSL (provided by Crypt::SSLeay): http://search.cpan.org/perldoc?Crypt::SSLeay or IO::Socket::SSL: http://search.cpan.org/perldoc?IO::Socket::SSL
If you think you have login problems, check this first!
creates new object Rapid7::NeXpose::API
my $n = Rapid7::NeXpose::API->new( url=>'https://localhost:3780', debug=>1, user=>'user', password=>'test', nologin=>1 );
get/set NeXpose base URL
get/set NeXpose API URL
set NeXpose credentials, returns $user
set NeXpose credentials, returns $password
set NeXpose session-id, returns $session
set NeXpose sync-id, returns $id
get/set LWP debugging
perform XML request to nexpose
perform api request to nexpose and return content
login to NeXpose
sends logout request, returns 1 on success, 0 on failure
list sites, returns list of sites
scan site specified by ID
delete site specified by ID
destructor, calls logout method on destruction
Vlatko Kosturjak, <kost at linux.hr>
<kost at linux.hr>
Please report any bugs or feature requests to bug-rapid7-nexpose-api at rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Rapid7-NeXpose-API. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
bug-rapid7-nexpose-api at rt.cpan.org
You can find documentation for this module with the perldoc command.
perldoc Rapid7::NeXpose::API
You can also look for information at:
RT: CPAN's request tracker
http://rt.cpan.org/NoAuth/Bugs.html?Dist=Rapid7-NeXpose-API
AnnoCPAN: Annotated CPAN documentation
http://annocpan.org/dist/Rapid7-NeXpose-API
CPAN Ratings
http://cpanratings.perl.org/d/Rapid7-NeXpose-API
Search CPAN
http://search.cpan.org/dist/Rapid7-NeXpose-API/
Repository is available on GitHub: https://github.com/kost/rapid7-nexpose-api-perl
Copyright 2010 Vlatko Kosturjak.
This program is free software; you can redistribute it and/or modify it under the terms of either: the GNU General Public License as published by the Free Software Foundation; or the Artistic License.
See http://dev.perl.org/licenses/ for more information.
To install Rapid7::NeXpose::API, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Rapid7::NeXpose::API
CPAN shell
perl -MCPAN -e shell install Rapid7::NeXpose::API
For more information on module installation, please visit the detailed CPAN module installation guide.