Scanner Groups¶
The following methods allow for interaction into the Tenable Vulnerability Management scanner-groups API endpoints.
Methods available on tio.scanner_groups
:
- class ScannerGroupsAPI(api: APISession)[source]¶
This will contain all methods related to scanner groups
- add_scanner(group_id, scanner_id)[source]¶
Add a scanner to a scanner group.
- Parameters:
- Returns:
Scanner successfully added to the scanner group.
- Return type:
Examples
>>> tio.scanner_groups.add_scanner(1, 1)
- create(name, group_type=None)[source]¶
Create a scanner group.
- Parameters:
- Returns:
The scanner group resource record for the created group.
- Return type:
Example
>>> group = tio.scanner_groups.create('Scanner Group')
- delete(group_id)[source]¶
Deletes a scanner group.
- Parameters:
group_id (int) – The unique identifier for the scanner group to delete.
- Returns:
The scanner group has been successfully deleted.
- Return type:
Examples
>>> tio.scanner_groups.delete(1)
- delete_scanner(group_id, scanner_id)[source]¶
Removes a scanner from a scanner group.
scanner-groups: delete-scanner
- Parameters:
- Returns:
The scanner was successfully removed from the scanner group.
- Return type:
Examples
>>> tio.scanner_groups.delete_scanner(1, 1)
- details(group_id)[source]¶
Retrieves the details about a scanner group.
- Parameters:
group_id (int) – The unique identifier for the scanner group.
- Returns:
The scanner group resource record.
- Return type:
Examples
>>> group = tio.scanner_groups.details(1) >>> pprint(group)
- edit(group_id, name)[source]¶
Modifies a scanner group.
- Parameters:
- Returns:
The scanner group has been successfully updated.
- Return type:
Examples
>>> tio.scanner_groups.edit(1, 'New Group Name')
- edit_routes(group_id, routes)[source]¶
Updates the hostnames, hostname wildcards, IP addresses, and IP address ranges that Tenable Vulnerability Management matches against targets in auto-routed scans
- list()[source]¶
Lists the configured scanner groups.
- Returns:
List of scanner group resource records.
- Return type:
Examples
>>> for group in tio.scanner_groups.list(): ... pprint(group)
- list_routes(group_id)[source]¶
List the hostnames, wildcards, IP addresses, and IP address ranges that Tenable Vulnerability Management matches against targets in auto-routed scans
- list_scanners(group_id)[source]¶
List the scanners within a specific scanner group.
- Parameters:
group_id (int) – The unique identifier of the scanner group.
- Returns:
List of scanner resource records associated to the scanner group.
- Return type:
Examples
>>> for scanner in tio.scanner_groups.list_scanners(1): ... pprint(scanner)