public class Ascan extends AscanDeprecated
| Modifier and Type | Method and Description |
|---|---|
ApiResponse |
addExcludedParam(java.lang.String name,
java.lang.String type,
java.lang.String url)
Adds a new parameter excluded from the scan, using the specified name.
|
ApiResponse |
addScanPolicy(java.lang.String scanpolicyname) |
ApiResponse |
addScanPolicy(java.lang.String scanpolicyname,
java.lang.String alertthreshold,
java.lang.String attackstrength) |
ApiResponse |
alertsIds(java.lang.String scanid)
Gets the IDs of the alerts raised during the scan with the given ID.
|
ApiResponse |
attackModeQueue() |
ApiResponse |
clearExcludedFromScan()
Clears the regexes of URLs excluded from the active scans.
|
ApiResponse |
disableAllScanners(java.lang.String scanpolicyname)
Disables all scanners of the scan policy with the given name, or the default if none given.
|
ApiResponse |
disableScanners(java.lang.String ids,
java.lang.String scanpolicyname)
Disables the scanners with the given IDs (comma separated list of IDs) of the scan policy
with the given name, or the default if none given.
|
ApiResponse |
enableAllScanners(java.lang.String scanpolicyname)
Enables all scanners of the scan policy with the given name, or the default if none given.
|
ApiResponse |
enableScanners(java.lang.String ids,
java.lang.String scanpolicyname)
Enables the scanners with the given IDs (comma separated list of IDs) of the scan policy with
the given name, or the default if none given.
|
ApiResponse |
excludedFromScan()
Gets the regexes of URLs excluded from the active scans.
|
ApiResponse |
excludedParams()
Gets all the parameters that are excluded.
|
ApiResponse |
excludedParamTypes()
Gets all the types of excluded parameters.
|
ApiResponse |
excludeFromScan(java.lang.String regex)
Adds a regex of URLs that should be excluded from the active scans.
|
ApiResponse |
importScanPolicy(java.lang.String path)
Imports a Scan Policy using the given file system path.
|
ApiResponse |
messagesIds(java.lang.String scanid)
Gets the IDs of the messages sent during the scan with the given ID.
|
ApiResponse |
modifyExcludedParam(java.lang.String idx,
java.lang.String name,
java.lang.String type,
java.lang.String url)
Modifies a parameter excluded from the scan.
|
ApiResponse |
optionAddQueryParam()
Tells whether or not the active scanner should add a query parameter to GET request that
don't have parameters to start with.
|
ApiResponse |
optionAllowAttackOnStart() |
ApiResponse |
optionAttackPolicy() |
ApiResponse |
optionDefaultPolicy() |
ApiResponse |
optionDelayInMs() |
ApiResponse |
optionExcludedParamList()
Deprecated.
|
ApiResponse |
optionHandleAntiCSRFTokens() |
ApiResponse |
optionHostPerScan() |
ApiResponse |
optionInjectPluginIdInHeader()
Tells whether or not the active scanner should inject the HTTP request header X-ZAP-Scan-ID,
with the ID of the scanner that's sending the requests.
|
ApiResponse |
optionMaxChartTimeInMins() |
ApiResponse |
optionMaxResultsToList() |
ApiResponse |
optionMaxRuleDurationInMins() |
ApiResponse |
optionMaxScanDurationInMins() |
ApiResponse |
optionMaxScansInUI() |
ApiResponse |
optionPromptInAttackMode() |
ApiResponse |
optionPromptToClearFinishedScans() |
ApiResponse |
optionRescanInAttackMode() |
ApiResponse |
optionScanHeadersAllRequests()
Tells whether or not the HTTP Headers of all requests should be scanned.
|
ApiResponse |
optionShowAdvancedDialog() |
ApiResponse |
optionTargetParamsEnabledRPC() |
ApiResponse |
optionTargetParamsInjectable() |
ApiResponse |
optionThreadPerHost() |
ApiResponse |
pause(java.lang.String scanid) |
ApiResponse |
pauseAllScans() |
ApiResponse |
policies(java.lang.String scanpolicyname,
java.lang.String policyid) |
ApiResponse |
removeAllScans() |
ApiResponse |
removeExcludedParam(java.lang.String idx)
Removes a parameter excluded from the scan, with the given index.
|
ApiResponse |
removeScan(java.lang.String scanid) |
ApiResponse |
removeScanPolicy(java.lang.String scanpolicyname) |
ApiResponse |
resume(java.lang.String scanid) |
ApiResponse |
resumeAllScans() |
ApiResponse |
scan(java.lang.String url,
java.lang.String recurse,
java.lang.String inscopeonly,
java.lang.String scanpolicyname,
java.lang.String method,
java.lang.String postdata) |
ApiResponse |
scan(java.lang.String url,
java.lang.String recurse,
java.lang.String inscopeonly,
java.lang.String scanpolicyname,
java.lang.String method,
java.lang.String postdata,
java.lang.Integer contextid)
Runs the active scanner against the given URL and/or Context.
|
ApiResponse |
scanAsUser(java.lang.String url,
java.lang.String contextid,
java.lang.String userid,
java.lang.String recurse,
java.lang.String scanpolicyname,
java.lang.String method,
java.lang.String postdata)
Active Scans from the perspective of a User, obtained using the given Context ID and User ID.
|
ApiResponse |
scanners(java.lang.String scanpolicyname,
java.lang.String policyid)
Gets the scanners, optionally, of the given scan policy and/or scanner policy/category ID.
|
ApiResponse |
scanPolicyNames() |
ApiResponse |
scanProgress(java.lang.String scanid) |
ApiResponse |
scans() |
ApiResponse |
setEnabledPolicies(java.lang.String ids,
java.lang.String scanpolicyname) |
ApiResponse |
setOptionAddQueryParam(boolean bool)
Sets whether or not the active scanner should add a query param to GET requests which do not
have parameters to start with.
|
ApiResponse |
setOptionAllowAttackOnStart(boolean bool) |
ApiResponse |
setOptionAttackPolicy(java.lang.String string) |
ApiResponse |
setOptionDefaultPolicy(java.lang.String string) |
ApiResponse |
setOptionDelayInMs(int i) |
ApiResponse |
setOptionHandleAntiCSRFTokens(boolean bool) |
ApiResponse |
setOptionHostPerScan(int i) |
ApiResponse |
setOptionInjectPluginIdInHeader(boolean bool)
Sets whether or not the active scanner should inject the HTTP request header X-ZAP-Scan-ID,
with the ID of the scanner that's sending the requests.
|
ApiResponse |
setOptionMaxChartTimeInMins(int i) |
ApiResponse |
setOptionMaxResultsToList(int i) |
ApiResponse |
setOptionMaxRuleDurationInMins(int i) |
ApiResponse |
setOptionMaxScanDurationInMins(int i) |
ApiResponse |
setOptionMaxScansInUI(int i) |
ApiResponse |
setOptionPromptInAttackMode(boolean bool) |
ApiResponse |
setOptionPromptToClearFinishedScans(boolean bool) |
ApiResponse |
setOptionRescanInAttackMode(boolean bool) |
ApiResponse |
setOptionScanHeadersAllRequests(boolean bool)
Sets whether or not the HTTP Headers of all requests should be scanned.
|
ApiResponse |
setOptionShowAdvancedDialog(boolean bool) |
ApiResponse |
setOptionTargetParamsEnabledRPC(int i) |
ApiResponse |
setOptionTargetParamsInjectable(int i) |
ApiResponse |
setOptionThreadPerHost(int i) |
ApiResponse |
setPolicyAlertThreshold(java.lang.String id,
java.lang.String alertthreshold,
java.lang.String scanpolicyname) |
ApiResponse |
setPolicyAttackStrength(java.lang.String id,
java.lang.String attackstrength,
java.lang.String scanpolicyname) |
ApiResponse |
setScannerAlertThreshold(java.lang.String id,
java.lang.String alertthreshold,
java.lang.String scanpolicyname) |
ApiResponse |
setScannerAttackStrength(java.lang.String id,
java.lang.String attackstrength,
java.lang.String scanpolicyname) |
ApiResponse |
skipScanner(java.lang.String scanid,
java.lang.String scannerid)
Skips the scanner using the given IDs of the scan and the scanner.
|
ApiResponse |
status(java.lang.String scanid) |
ApiResponse |
stop(java.lang.String scanid) |
ApiResponse |
stopAllScans() |
ApiResponse |
updateScanPolicy(java.lang.String scanpolicyname,
java.lang.String alertthreshold,
java.lang.String attackstrength) |
addScanPolicy, clearExcludedFromScan, disableAllScanners, disableScanners, enableAllScanners, enableScanners, excludeFromScan, pause, pauseAllScans, removeAllScans, removeScan, removeScanPolicy, resume, resumeAllScans, scan, scanAsUser, setEnabledPolicies, setOptionAllowAttackOnStart, setOptionAttackPolicy, setOptionDefaultPolicy, setOptionDelayInMs, setOptionHandleAntiCSRFTokens, setOptionHostPerScan, setOptionInjectPluginIdInHeader, setOptionMaxChartTimeInMins, setOptionMaxResultsToList, setOptionMaxScansInUI, setOptionPromptInAttackMode, setOptionPromptToClearFinishedScans, setOptionRescanInAttackMode, setOptionScanHeadersAllRequests, setOptionShowAdvancedDialog, setOptionTargetParamsEnabledRPC, setOptionTargetParamsInjectable, setOptionThreadPerHost, setPolicyAlertThreshold, setPolicyAttackStrength, setScannerAlertThreshold, setScannerAttackStrength, stop, stopAllScanspublic Ascan(ClientApi api)
public ApiResponse status(java.lang.String scanid) throws ClientApiException
ClientApiExceptionpublic ApiResponse scanProgress(java.lang.String scanid) throws ClientApiException
ClientApiExceptionpublic ApiResponse messagesIds(java.lang.String scanid) throws ClientApiException
ClientApiExceptionpublic ApiResponse alertsIds(java.lang.String scanid) throws ClientApiException
ClientApiExceptionpublic ApiResponse scans() throws ClientApiException
ClientApiExceptionpublic ApiResponse scanPolicyNames() throws ClientApiException
ClientApiExceptionpublic ApiResponse excludedFromScan() throws ClientApiException
ClientApiExceptionpublic ApiResponse scanners(java.lang.String scanpolicyname, java.lang.String policyid) throws ClientApiException
ClientApiExceptionpublic ApiResponse policies(java.lang.String scanpolicyname, java.lang.String policyid) throws ClientApiException
ClientApiExceptionpublic ApiResponse attackModeQueue() throws ClientApiException
ClientApiExceptionpublic ApiResponse excludedParams() throws ClientApiException
ClientApiException@Deprecated public ApiResponse optionExcludedParamList() throws ClientApiException
ClientApiExceptionpublic ApiResponse excludedParamTypes() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionAttackPolicy() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionDefaultPolicy() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionDelayInMs() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionHandleAntiCSRFTokens() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionHostPerScan() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionMaxChartTimeInMins() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionMaxResultsToList() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionMaxRuleDurationInMins() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionMaxScanDurationInMins() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionMaxScansInUI() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionTargetParamsEnabledRPC() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionTargetParamsInjectable() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionThreadPerHost() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionAddQueryParam() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionAllowAttackOnStart() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionInjectPluginIdInHeader() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionPromptInAttackMode() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionPromptToClearFinishedScans() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionRescanInAttackMode() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionScanHeadersAllRequests() throws ClientApiException
ClientApiExceptionpublic ApiResponse optionShowAdvancedDialog() throws ClientApiException
ClientApiExceptionpublic ApiResponse scan(java.lang.String url, java.lang.String recurse, java.lang.String inscopeonly, java.lang.String scanpolicyname, java.lang.String method, java.lang.String postdata) throws ClientApiException
ClientApiExceptionpublic ApiResponse scan(java.lang.String url, java.lang.String recurse, java.lang.String inscopeonly, java.lang.String scanpolicyname, java.lang.String method, java.lang.String postdata, java.lang.Integer contextid) throws ClientApiException
ClientApiExceptionpublic ApiResponse scanAsUser(java.lang.String url, java.lang.String contextid, java.lang.String userid, java.lang.String recurse, java.lang.String scanpolicyname, java.lang.String method, java.lang.String postdata) throws ClientApiException
ClientApiExceptionpublic ApiResponse pause(java.lang.String scanid) throws ClientApiException
ClientApiExceptionpublic ApiResponse resume(java.lang.String scanid) throws ClientApiException
ClientApiExceptionpublic ApiResponse stop(java.lang.String scanid) throws ClientApiException
ClientApiExceptionpublic ApiResponse removeScan(java.lang.String scanid) throws ClientApiException
ClientApiExceptionpublic ApiResponse pauseAllScans() throws ClientApiException
ClientApiExceptionpublic ApiResponse resumeAllScans() throws ClientApiException
ClientApiExceptionpublic ApiResponse stopAllScans() throws ClientApiException
ClientApiExceptionpublic ApiResponse removeAllScans() throws ClientApiException
ClientApiExceptionpublic ApiResponse clearExcludedFromScan() throws ClientApiException
ClientApiExceptionpublic ApiResponse excludeFromScan(java.lang.String regex) throws ClientApiException
ClientApiExceptionpublic ApiResponse enableAllScanners(java.lang.String scanpolicyname) throws ClientApiException
ClientApiExceptionpublic ApiResponse disableAllScanners(java.lang.String scanpolicyname) throws ClientApiException
ClientApiExceptionpublic ApiResponse enableScanners(java.lang.String ids, java.lang.String scanpolicyname) throws ClientApiException
ClientApiExceptionpublic ApiResponse disableScanners(java.lang.String ids, java.lang.String scanpolicyname) throws ClientApiException
ClientApiExceptionpublic ApiResponse setEnabledPolicies(java.lang.String ids, java.lang.String scanpolicyname) throws ClientApiException
ClientApiExceptionpublic ApiResponse setPolicyAttackStrength(java.lang.String id, java.lang.String attackstrength, java.lang.String scanpolicyname) throws ClientApiException
ClientApiExceptionpublic ApiResponse setPolicyAlertThreshold(java.lang.String id, java.lang.String alertthreshold, java.lang.String scanpolicyname) throws ClientApiException
ClientApiExceptionpublic ApiResponse setScannerAttackStrength(java.lang.String id, java.lang.String attackstrength, java.lang.String scanpolicyname) throws ClientApiException
ClientApiExceptionpublic ApiResponse setScannerAlertThreshold(java.lang.String id, java.lang.String alertthreshold, java.lang.String scanpolicyname) throws ClientApiException
ClientApiExceptionpublic ApiResponse addScanPolicy(java.lang.String scanpolicyname) throws ClientApiException
ClientApiExceptionpublic ApiResponse addScanPolicy(java.lang.String scanpolicyname, java.lang.String alertthreshold, java.lang.String attackstrength) throws ClientApiException
ClientApiExceptionpublic ApiResponse removeScanPolicy(java.lang.String scanpolicyname) throws ClientApiException
ClientApiExceptionpublic ApiResponse updateScanPolicy(java.lang.String scanpolicyname, java.lang.String alertthreshold, java.lang.String attackstrength) throws ClientApiException
ClientApiExceptionpublic ApiResponse importScanPolicy(java.lang.String path) throws ClientApiException
ClientApiExceptionpublic ApiResponse addExcludedParam(java.lang.String name, java.lang.String type, java.lang.String url) throws ClientApiException
ClientApiExceptionpublic ApiResponse modifyExcludedParam(java.lang.String idx, java.lang.String name, java.lang.String type, java.lang.String url) throws ClientApiException
ClientApiExceptionpublic ApiResponse removeExcludedParam(java.lang.String idx) throws ClientApiException
ClientApiExceptionpublic ApiResponse skipScanner(java.lang.String scanid, java.lang.String scannerid) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionAttackPolicy(java.lang.String string) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionDefaultPolicy(java.lang.String string) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionAddQueryParam(boolean bool) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionAllowAttackOnStart(boolean bool) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionDelayInMs(int i) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionHandleAntiCSRFTokens(boolean bool) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionHostPerScan(int i) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionInjectPluginIdInHeader(boolean bool) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionMaxChartTimeInMins(int i) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionMaxResultsToList(int i) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionMaxRuleDurationInMins(int i) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionMaxScanDurationInMins(int i) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionMaxScansInUI(int i) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionPromptInAttackMode(boolean bool) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionPromptToClearFinishedScans(boolean bool) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionRescanInAttackMode(boolean bool) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionScanHeadersAllRequests(boolean bool) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionShowAdvancedDialog(boolean bool) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionTargetParamsEnabledRPC(int i) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionTargetParamsInjectable(int i) throws ClientApiException
ClientApiExceptionpublic ApiResponse setOptionThreadPerHost(int i) throws ClientApiException
ClientApiException