我想使用python客户端创建Nessus Security Scanner并通过getStatus检查状态,并通过getReport方法获取结果 . 虽然,我已经通过php(SoftLayer API Nessus Scan Status / Report via PHP)阅读了这些帮助 . 但是如何通过python客户端使用这些?当我通过python调用setInitParameter(scan_id)时,异常如flow:SoftLayerAPIError(Client):Function("setInitParameter")不是此服务的有效方法
1 回答
我建议你先阅读客户的文档:
https://github.com/softlayer/softlayer-python https://softlayer-api-python-client.readthedocs.io/en/latest/
init参数设置如下:
在这里您可以找到使用客户端的更多示例:
https://softlayer.github.io/python/
在这里您可以找到其他文档:
http://sldn.softlayer.com/blog
并重新说明,与Softlayer的python客户端不同,php客户端数据以json格式发送,因此请求:
会是这样的: