Errors

class AuthenticationWarning[source]

An authentication warning is thrown when an unauthenticated API session is initiated.

class FileDownloadError(resource: str, resource_id: str, filename: str)[source]

FileDownloadError is thrown when a file fails to download.

msg

The error message

Type:

str

filename

The Filename or file id that was requested.

Type:

str

resource

The resource that the file was requested from (e.g. “scans”)

Type:

str

resource_id

The identifier for the resource that was requested.

Type:

str

class ImpersonationError(resp, **kwargs)[source]

An ImpersonationError exists when there is an issue with user impersonation.

code

The HTTP response code from the offending response.

Type:

int

response

This is the Response object that had caused the Exception to fire.

Type:

request.Response

uuid

The Request UUID of the request. This can be used for the purpose of tracking the request and the response through the Tenable.io infrastructure. In the case of Non-Tenable.io products, is simply an empty string.

Type:

str

class PasswordComplexityError(resp, **kwargs)[source]

PasswordComplexityError is thrown when attempting to change a password and the password complexity is insufficient.

code

The HTTP response code from the offending response.

Type:

int

response

This is the Response object that had caused the Exception to fire.

Type:

request.Response

uuid

The Request UUID of the request. This can be used for the purpose of tracking the request and the response through the Tenable.io infrastructure. In the case of Non-Tenable.io products, is simply an empty string.

Type:

str

class TioExportsError(export: str, uuid: str, msg: str | None = None)[source]

When the exports APIs throw an error when processing an export, pyTenable will throw this error in turn to relay that context to the user.

class TioExportsTimeout(export: str, uuid: str, msg: str | None = None)[source]

When an export has been cancelled due to timeout, this error is thrown.