Home ⌂Doc Index ◂Up ▴

eric6.WebBrowser.VirusTotal.VirusTotalApi

Module implementing the VirusTotal API class.

Global Attributes

None

Classes

VirusTotalAPI Class implementing the VirusTotal API.

Functions

None


VirusTotalAPI

Class implementing the VirusTotal API.

Signals

checkServiceKeyFinished(bool, str)
emitted after the service key check has been performed. It gives a flag indicating validity (boolean) and an error message in case of a network error (string).
fileScanReport(str)
emitted with the URL of the file scan report page
submitUrlError(str)
emitted with the error string, if the URL scan submission returned an error.
urlScanReport(str)
emitted with the URL of the URL scan report page

Derived from

QObject

Class Attributes

GetDomainReportPattern
GetFileReportPattern
GetIpAddressReportPattern
GetUrlReportPattern
ScanUrlPattern
ServiceCode_InvalidKey
ServiceCode_InvalidPrivilege
ServiceCode_RateLimitExceeded
ServiceResult_ItemNotPresent
ServiceResult_ItemPresent
ServiceResult_ItemQueued
TestServiceKeyScanID

Class Methods

None

Methods

VirusTotalAPI Constructor
__checkServiceKeyValidityFinished Private slot to determine the result of the service key validity check.
__getDomainReportFinished Private slot to process the IP address report data.
__getFileScanReportUrl Private method to get the report URL for a file scan.
__getFileScanReportUrlFinished Private slot to determine the result of the file scan report URL request.
__getIpAddressReportFinished Private slot to process the IP address report data.
__getUrlScanReportUrl Private method to get the report URL for a URL scan.
__getUrlScanReportUrlFinished Private slot to determine the result of the URL scan report URL.
__loadSettings Private method to load the settings.
__submitUrlFinished Private slot to determine the result of the URL scan submission.
checkServiceKeyValidity Public method to check the validity of the given service key.
close Public slot to close the API.
getDomainReport Public method to retrieve a report for a domain.
getIpAddressReport Public method to retrieve a report for an IP address.
preferencesChanged Public slot to handle a change of preferences.
submitUrl Public method to submit an URL to be scanned.

Static Methods

None

VirusTotalAPI (Constructor)

VirusTotalAPI(parent=None)

Constructor

parent
reference to the parent object (QObject)

VirusTotalAPI.__checkServiceKeyValidityFinished

__checkServiceKeyValidityFinished(reply)

Private slot to determine the result of the service key validity check.

reply (QNetworkReply)
reference to the network reply

VirusTotalAPI.__getDomainReportFinished

__getDomainReportFinished(reply)

Private slot to process the IP address report data.

reply (QNetworkReply)
reference to the network reply

VirusTotalAPI.__getFileScanReportUrl

__getFileScanReportUrl(scanId)

Private method to get the report URL for a file scan.

scanId
ID of the scan to get the report URL for (string)

VirusTotalAPI.__getFileScanReportUrlFinished

__getFileScanReportUrlFinished(reply)

Private slot to determine the result of the file scan report URL request.

reply (QNetworkReply)
reference to the network reply

VirusTotalAPI.__getIpAddressReportFinished

__getIpAddressReportFinished(reply)

Private slot to process the IP address report data.

reply (QNetworkReply)
reference to the network reply

VirusTotalAPI.__getUrlScanReportUrl

__getUrlScanReportUrl(scanId)

Private method to get the report URL for a URL scan.

scanId
ID of the scan to get the report URL for (string)

VirusTotalAPI.__getUrlScanReportUrlFinished

__getUrlScanReportUrlFinished(reply)

Private slot to determine the result of the URL scan report URL.

reply (QNetworkReply)
reference to the network reply request.

VirusTotalAPI.__loadSettings

__loadSettings()

Private method to load the settings.

VirusTotalAPI.__submitUrlFinished

__submitUrlFinished(reply)

Private slot to determine the result of the URL scan submission.

reply (QNetworkReply)
reference to the network reply

VirusTotalAPI.checkServiceKeyValidity

checkServiceKeyValidity(key, protocol="")

Public method to check the validity of the given service key.

key
service key (string)
protocol
protocol used to access VirusTotal (string)

VirusTotalAPI.close

close()

Public slot to close the API.

VirusTotalAPI.getDomainReport

getDomainReport(domain)

Public method to retrieve a report for a domain.

domain (str)
domain name

VirusTotalAPI.getIpAddressReport

getIpAddressReport(ipAddress)

Public method to retrieve a report for an IP address.

ipAddress (str)
valid IPv4 address in dotted quad notation

VirusTotalAPI.preferencesChanged

preferencesChanged()

Public slot to handle a change of preferences.

VirusTotalAPI.submitUrl

submitUrl(url)

Public method to submit an URL to be scanned.

url
url to be scanned (QUrl)
Up



Home ⌂Doc Index ◂Up ▴