Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
giterlizzi committed Jul 22, 2020
2 parents c7cc2d6 + a97345a commit 5cc2b3b
Show file tree
Hide file tree
Showing 57 changed files with 3,669 additions and 464 deletions.
36 changes: 32 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,35 @@
language: perl
perl:
- "5.22"
- "5.24"
- "5.26"
- "5.28"
- "5.30"
- "5.28"
- "5.26"
- "5.24"
- "5.22"
- "5.20"
- "5.18"
- "5.16"
- "5.14"
- "5.12"
- "5.10"
- "5.8"
matrix:
include:
- perl: 5.30
env: COVERAGE=1
install:
- cpan-install --deps
- cpan-install --coverage
before_script:
- coverage-setup
after_success:
- coverage-report
cache:
directories:
- $HOME/perl5
before_install:
- git clone git://github.com/travis-perl/helpers ~/travis-perl-helpers
- source ~/travis-perl-helpers/init --always-upgrade-modules
- build-perl
- perl -V
- build-dist
- cd $BUILD_DIR
19 changes: 16 additions & 3 deletions Changes
Original file line number Diff line number Diff line change
@@ -1,5 +1,18 @@
Revision history for Net::SecurityCenter

0.206 2020/07/22
- Refactoring "Net::SecurityCenter" class
- Added "Net::SecurityCenter::API::Status" class
- Added "Net::SecurityCenter::API::DeviceInfo" class (added in Tenable.sc 5.12)
- Added "Net::SecurityCenter::API::System->debug" method (added in Tenable.sc 5.10)
- Deprecated "Net::SecurityCenter::API::System->get_status" method
- Deprecated "Net::SecurityCenter::API::System->get_info" method
- Improved "Net::SecurityCenter::API::ScanResult->list" method (added "start_time" and "end_time" params)
- Fixed unhexpected behavior in "Net::SecurityCenter::API::ScanResult->list" method for "start_date" and "end_date" params
- Improved sc-api command
- Improved documentations
- Added more tests

0.205 2020/01/31
- Added new Net::SecurityCenter::API::ScanResult methods
- import
Expand All @@ -13,9 +26,9 @@ Revision history for Net::SecurityCenter
0.203 2019/10/29
- Added initial support for Tenable.sc 5.12
- Added "Net::SecurityCenter::API::Scanner::health" method
- Renamed "Net::SecurityCenter::API::Scanner::get_status" method to "Net::SecurityCenter::API::Scanner::status"
- Renamed "Net::SecurityCenter::API::ScanResult::get_status" method to "Net::SecurityCenter::API::ScanResult::status"
- Renamed "Net::SecurityCenter::API::ScanResult::get_progress" method to "Net::SecurityCenter::API::ScanResult::progress"
- Renamed "Net::SecurityCenter::API::Scanner->get_status" method to "Net::SecurityCenter::API::Scanner->status"
- Renamed "Net::SecurityCenter::API::ScanResult->get_status" method to "Net::SecurityCenter::API::ScanResult->status"
- Renamed "Net::SecurityCenter::API::ScanResult->get_progress" method to "Net::SecurityCenter::API::ScanResult->progress"

0.202 2019/09/10
- Added "download" method for Analysis API
Expand Down
2 changes: 1 addition & 1 deletion INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ You can also look for information at:

## LICENSE AND COPYRIGHT

Copyright (C) 2018-2019 Giuseppe Di Terlizzi
Copyright (C) 2018-2020 Giuseppe Di Terlizzi

This program is free software; you can redistribute it and/or modify it
under the terms of the the Artistic License (2.0). You may obtain a
Expand Down
4 changes: 2 additions & 2 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
This software is copyright (c) 2018-2019 by Giuseppe Di Terlizzi.
This software is copyright (c) 2018-2020 by Giuseppe Di Terlizzi.

This is free software; you can redistribute it and/or modify it under
the same terms as the Perl 5 programming language system itself.
Expand All @@ -12,7 +12,7 @@ b) the "Artistic License"

--- The GNU General Public License, Version 1, February 1989 ---

This software is Copyright (c) 2018-2019 by Giuseppe Di Terlizzi.
This software is Copyright (c) 2018-2020 by Giuseppe Di Terlizzi.

This is free software, licensed under:

Expand Down
27 changes: 27 additions & 0 deletions MANIFEST
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ lib/Net/SecurityCenter.pm
lib/Net/SecurityCenter/API.pm
lib/Net/SecurityCenter/API/Analysis.pm
lib/Net/SecurityCenter/API/Credential.pm
lib/Net/SecurityCenter/API/DeviceInfo.pm
lib/Net/SecurityCenter/API/Feed.pm
lib/Net/SecurityCenter/API/File.pm
lib/Net/SecurityCenter/API/Plugin.pm
Expand All @@ -15,6 +16,7 @@ lib/Net/SecurityCenter/API/Repository.pm
lib/Net/SecurityCenter/API/Scan.pm
lib/Net/SecurityCenter/API/Scanner.pm
lib/Net/SecurityCenter/API/ScanResult.pm
lib/Net/SecurityCenter/API/Status.pm
lib/Net/SecurityCenter/API/System.pm
lib/Net/SecurityCenter/API/User.pm
lib/Net/SecurityCenter/API/Zone.pm
Expand All @@ -27,13 +29,38 @@ MANIFEST This list of files
README.md
t/00-load.t
t/10-rest.t
t/20-utils.t
t/99-local.t
t/manifest.t
t/mock/rest-plugin-0-get.json
t/mock/rest-plugin-get.json
t/mock/rest-pluginFamily-1000030-get.json
t/mock/rest-pluginFamily-2-plugins-get.json
t/mock/rest-pluginFamily-get.json
t/mock/rest-policy-1-get.json
t/mock/rest-policy-get.json
t/mock/rest-report-1-get.json
t/mock/rest-report-get.json
t/mock/rest-repository-37-get.json
t/mock/rest-repository-get.json
t/mock/rest-scan-2-launch-post.json
t/mock/rest-scan-4-get.json
t/mock/rest-scan-get.json
t/mock/rest-scanner-5-get.json
t/mock/rest-scanner-5-health-get.json
t/mock/rest-scanner-get.json
t/mock/rest-scanResult-11-get.json
t/mock/rest-scanResult-86-pause-post.json
t/mock/rest-scanResult-86-resume-post.json
t/mock/rest-scanResult-86-stop-post.json
t/mock/rest-scanResult-get.json
t/mock/rest-status-get.json
t/mock/rest-system-debug-get.json
t/mock/rest-system-diagnostics-get.json
t/mock/rest-system-get.json
t/mock/rest-token-delete.json
t/mock/rest-token-post.json
t/mock/rest-zone-5-get.json
t/mock/rest-zone-get.json
t/pod-coverage.t
t/pod.t
30 changes: 15 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,29 +1,29 @@
[![Release](https://img.shields.io/github/release/giterlizzi/perl-Net-SecurityCenter.svg)](https://github.com/giterlizzi/perl-Net-SecurityCenter/releases) [![Build Status](https://travis-ci.org/giterlizzi/perl-Net-SecurityCenter.svg)](https://travis-ci.org/giterlizzi/perl-Net-SecurityCenter) [![License](https://img.shields.io/github/license/giterlizzi/perl-Net-SecurityCenter.svg)](https://github.com/giterlizzi/perl-Net-SecurityCenter) [![Starts](https://img.shields.io/github/stars/giterlizzi/perl-Net-SecurityCenter.svg)](https://github.com/giterlizzi/perl-Net-SecurityCenter) [![Forks](https://img.shields.io/github/forks/giterlizzi/perl-Net-SecurityCenter.svg)](https://github.com/giterlizzi/perl-Net-SecurityCenter) [![Issues](https://img.shields.io/github/issues/giterlizzi/perl-Net-SecurityCenter.svg)](https://github.com/giterlizzi/perl-Net-SecurityCenter/issues)
[![Release](https://img.shields.io/github/release/giterlizzi/perl-Net-SecurityCenter.svg)](https://github.com/giterlizzi/perl-Net-SecurityCenter/releases) [![Build Status](https://travis-ci.org/giterlizzi/perl-Net-SecurityCenter.svg)](https://travis-ci.org/giterlizzi/perl-Net-SecurityCenter) [![License](https://img.shields.io/github/license/giterlizzi/perl-Net-SecurityCenter.svg)](https://github.com/giterlizzi/perl-Net-SecurityCenter) [![Starts](https://img.shields.io/github/stars/giterlizzi/perl-Net-SecurityCenter.svg)](https://github.com/giterlizzi/perl-Net-SecurityCenter) [![Forks](https://img.shields.io/github/forks/giterlizzi/perl-Net-SecurityCenter.svg)](https://github.com/giterlizzi/perl-Net-SecurityCenter) [![Issues](https://img.shields.io/github/issues/giterlizzi/perl-Net-SecurityCenter.svg)](https://github.com/giterlizzi/perl-Net-SecurityCenter/issues) [![Coverage Status](https://coveralls.io/repos/github/giterlizzi/perl-Net-SecurityCenter/badge.svg)](https://coveralls.io/github/giterlizzi/perl-Net-SecurityCenter)

# Net::SecurityCenter - Perl interface to Tenable.sc (SecurityCenter) REST API

## Synopsis

```.pl
use Net::SecurityCenter;
my $sc = Net::SecurityCenter('sc.example.org') or die "Error: $@";
use Net::SecurityCenter;
my $sc = Net::SecurityCenter('sc.example.org') or die "Error: $@";

$sc->login('secman', 'password');
$sc->login('secman', 'password');

if ($sc->error) {
print "Failed login: " . $sc->error;
exit 0;
}
if ($sc->error) {
print "Failed login: " . $sc->error;
exit 0;
}

my $running_scans = $sc->scan_result->list_running;
my $running_scans = $sc->scan_result->list_running;

if ($sc->scan_result->status( id => 1337 ) eq 'completed') {
$sc->scan_result->download( id => 1337,
filename => '/tmp/1337.nessus' );
if ($sc->scan_result->status( id => 1337 ) eq 'completed') {
$sc->scan_result->download( id => 1337,
filename => '/tmp/1337.nessus' );

}
}

$sc->logout();
$sc->logout();
```

## Install
Expand All @@ -37,5 +37,5 @@ To install `Net::SecurityCenter` distribution, run the following commands:

## Copyright

- Copyright 2018-2019 © Giuseppe Di Terlizzi
- Copyright 2018-2020 © Giuseppe Di Terlizzi
- Nessus®, Tenable.sc® and SecurityCenter® is a Registered Trademark of Tenable®, Inc.
Loading

0 comments on commit 5cc2b3b

Please sign in to comment.