This add-on allows you to import and export ZAP data in a range of formats.
It supports the Automation Framework.
A context menu item to Copy URLs to the system clipboard.
A context menu item to save the selected HTTP messages in HAR format.
Provides a context menu to save content of HTTP messages as binary. (While the files will probably open in a simple editor it may have null characters or malformed bytes.)
Provides a context menu to save content of HTTP messages as XML.
An option to import messages from a HTTP Archive (HAR), available via the ‘Import’ menu. Note : The following modifications may be made when importing a HAR (HTTP Archive File):
Allows you to import log files from ModSecurity and files previously exported from ZAP.
An option to import a file of URLs is available via the ‘Import’ menu (‘Import a File Containing URLs’). The file must be plain text with one URL per line. Blank lines and lines starting with # will be ignored.
This allows you to prune URLs from the Sites Tree using a file in the Sites Tree format
The add-on also adds a top level “Export” menu, providing the following functionality.
This allows you to save requests and responses to a text file.
Select the messages to save in the History tab (including multi-select).
This allows you to save a specific responses to a file.
Select the relevant message in the History tab - note that binary responses (such as images) can be saved as well as text responses.
This allows you to save the Sites Tree in the Sites Tree format
This allows you to save all the accessed URLs to a text or HTML file.
This can be used, amongst other things, to compare the URLs available to users with different roles or permissions on the same system. (Also consider leveraging the Access Control Testing add-on.) This functionality is also available via the right-click context menu in the Sites tree panel.
All URLs in the Sites tree that fall within the selected node are exported. This functionality is also available from the right-click menu when used on a Site or Context node in the Sites tree panel.
This add-on also exposes various ZAP API endpoints to facilitate programmatic use of the functionality.
exportSitesTree (filePath* )
Exports the Sites Tree in the Sites Tree YAML format.importHar (filePath* )
Imports a HAR file.importModsec2Logs (filePath* )
Imports ModSecurity2 logs from the file with the given file system path.importUrls (filePath* )
Imports URLs (one per line) from the file with the given file system path.importZapLogs (filePath* )
Imports previously exported ZAP messages from the file with the given file system path.pruneSitesTree (filePath* )
Prunes the Sites Tree based on a file in the Sites Tree YAML format.exportHar (baseurl start count )
Gets the HTTP messages sent through/by ZAP, in HAR format, optionally filtered by URL and paginated with ‘start’ position and ‘count’ of messagesexportHarById (ids* )
Gets the HTTP messages with the given IDs, in HAR format.sendHarRequest (request* followRedirects )
Sends the first HAR request entry, optionally following redirections. Returns, in HAR format, the request sent and response received and followed redirections, if any. The Mode is enforced when sending the request (and following redirections), custom manual requests are not allowed in ‘Safe’ mode nor in ‘Protected’ mode if out of scope.