Closed quend closed 5 months ago
in addition, to create a project you must have at least a trial network scanner license
I was using a trial network scanner. Here is my code. I also noticed that the projects returned didn't reflect those in the UI.
api_key = "<Trial Key>"
vulners_api = vulners.VScannerApi(api_key=api_key)
print(vulners_api)
licenses = vulners_api.get_licenses()['licenseList']
print(licenses)
t = licenses[1]['type']
assert 'trial' == t
uuid = licenses[1]['id']
print(uuid)
notification = vulners_api.DisabledNotification()
projects = vulners_api.get_projects()
print(projects)
project = vulners_api.create_project(name="test",
license_id=uuid,
notification=notification)
projects = vulners_api.get_projects() print(len(projects)) ?
Result => 1
Its weird it seems to run once fine but then subsequent runs fails with the error:
requests.exceptions.HTTPError: 403 Client Error: Forbidden for url: https://vulners.com/api/v3/proxy/vscanner/projects
you can have only one project on a trial license
Trying out the v2 API to scan IP's. When I attempt to create a project I get a forbidden url error. Do you know why this would be?
project = vulners_api.create_project(name="my project", File "<string>", line 11, in create_project File "/Library/Python/3.8/site-packages/vulners-2.0.0-py3.8.egg/vulners/base.py", line 209, in _send_request File "/Library/Python/3.8/site-packages/requests/models.py", line 943, in raise_for_status raise HTTPError(http_error_msg, response=self) requests.exceptions.HTTPError: 403 Client Error: Forbidden for url: https://vulners.com/api/v3/proxy/vscanner/projects