带有特定前缀PYTHON的持久io下载扫描

时间:2018-07-09 14:03:57

标签: python python-3.x nessus

我正在尝试使用Python API下载名称为“ API”前缀的一组扫描。

我的代码如下:

from tenable_io.client import TenableIOClient
from tenable_io.api.scans import ScanExportRequest

client = TenableIOClient(access_key='ACCESS KEY', secret_key='SECRET KEY')
scans = {scan.name: scan.id for scan in client.scans_api.list().scans}
#scan = client.scan_helper.id(scans['{Test Scan API}'])
scan = client.scan_helper.id(name_regex=r'.*Test/sScan/sAPI.*')
scan.download('{Test Scan API}', format=ScanExportRequest.FORMAT_NESSUS) # Not sure what to put here to download

任何帮助将不胜感激!

0 个答案:

没有答案