Important

The Nessus Package is currently a Technology Preview

Mail

Methods described in this section relate to the mail API. These methods can be accessed at Nessus.mail.

class MailAPI(api: restfly.session.APISession)[source]
details() Dict[source]

Retrieves the Tenable Nessus daemon’s mail settings

Returns

Dictionary of SMTP settings

Return type

Dict

Example

>>> nessus.mail.details()
edit(smtp_host: typing.Optional[str] = None, smtp_port: typing.Optional[int] = None, smtp_enc: typing.Optional[typing_extensions.Literal[No Encryption, Use TLS if available, Force SSLForce TLS]] = None, smtp_from: typing.Optional[str] = None, smtp_www_host: typing.Optional[str] = None, smtp_user: typing.Optional[str] = None, smtp_pass: typing.Optional[str] = None, smtp_auth: typing.Optional[typing_extensions.Literal[NONE, PLAIN, LOGIN, NTLM, CRAM-MD5]] = None) None[source]

Updates the Tenable Nessus daemon’s mail settings

Parameters
  • smtp_host (str, optional) – DNS/IP Address of the SMTP server

  • smtp_port (int, optional) – Port number for the SMTP service

  • smtp_enc (str, optional) – The connection encryption for the SMTP server

  • smtp_from (str, optional) – Reply email address for email sent by the Tenable Nessus daemon

  • smtp_www_host (str, optional) – The host to use in email links

  • smtp_user (str, optional) – The username to use when authenticating to the SMTP service

  • smtp_pass (str, optional) – The password to use when authenticating to the SMTP service

  • smtp_auth (str, optional) – The authentication type for the SMTP server

Example

>>> nessus.mail.edit(smtp_user='new_user',
...                  smtp_pass='updated_password',
...                  smtp_auth='LOGIN',
...                  )