Format of a scan POST request

March 5, 2024

ID 193000

Scan POST requests have the following format:

* Request headers *

 

* Request body *

{

"timeout": "%TIMEOUT%",

"omitCleanSubobjectResults": %TO_OMIT_CLEAN_SUBOBJECT_RESULTS%,

"url": "%URL%",

"hostIp": "%HOST_IP%",

"requestHeaders": "%REQUEST_HEADERS%",

"responseHeaders": "%RESPONSE_HEADERS%",

"object": "%OBJECT%",

"name": "%SCAN_OBJECT_NAME%"

}

where:

  • timeout is the object scan timeout in milliseconds (ms). This field is optional.
  • omitCleanSubobjectResults is a binary flag that specifies whether the subObjectsScanResults array returned in the response must contain objects with the CLEAN scan result. If the value is true, such objects are omitted; if the value is false, such objects are retained. The default value is true. This field is optional.

    See also the detailed information about the structure of the subObjectsScanResults array.

  • url is the URL to use as the scan task context. This field is optional.

    This field can be used for increasing the detection rate.

  • hostIp is the IP of the host that hosts the scanned URL. This field is optional.

    This field can be used for increasing the detection rate. You need to enable KSN to use this field.

  • requestHeaders specifies the text of the HTTP request headers extracted from the HTTP transaction message. This field is optional.

    This field can be used for increasing the detection rate.

  • responseHeaders specifies the text of the HTTP response headers extracted from the HTTP transaction message. This field is optional.

    This field can be used for increasing the detection rate.

  • object is the full path to the file to scan (if a request is made to /api/v3.0/scanfile) or a Base64-encoded string (if a request is made to /api/v3.0/scanmemory). Only one object can be specified in this field. This field is mandatory.
  • name is the name of the object to scan in scanmemory mode (if a request is made to /api/v3.1/scanmemory). The value can be from 1 to 300 Unicode characters. This field is optional.

If the request body contains any special characters, they must be escaped in accordance with Standard ECMA-404 (The JSON Interchange Syntax).

Did you find this article helpful?
What can we do better?
Thank you for your feedback! You're helping us improve.
Thank you for your feedback! You're helping us improve.