-
Notifications
You must be signed in to change notification settings - Fork 18
Expand file tree
/
Copy pathIScanServiceProvider.java
More file actions
62 lines (52 loc) · 1.71 KB
/
Copy pathIScanServiceProvider.java
File metadata and controls
62 lines (52 loc) · 1.71 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
/**
* © Copyright IBM Corporation 2016.
* © Copyright HCL Technologies Ltd. 2017.
* LICENSE: Apache License, Version 2.0 https://www.apache.org/licenses/LICENSE-2.0
*/
package com.hcl.appscan.sdk.scan;
import java.io.File;
import java.io.IOException;
import java.util.Map;
import org.apache.wink.json4j.JSONException;
import org.apache.wink.json4j.JSONObject;
import com.hcl.appscan.sdk.auth.IAuthenticationProvider;
import com.hcl.appscan.sdk.logging.IProgress;
/**
* A provider of scanning services.
*/
public interface IScanServiceProvider {
/**
* Creates and executes a scan.
*
* @param type The type of scan to execute. For example DynamicAnalyzer, MobileAnalyzer, or StaticAnalyzer.
* @param params A Map of scan parameters.
* @return The id of the submitted scan, if successful. Otherwise, null.
*/
public String createAndExecuteScan(String type, Map<String, String> params);
/**
* Submits a file for scanning.
*
* @param file The file to submit.
* @return The id of the submitted file.
* @throws IOException
*/
public String submitFile(File file) throws IOException;
/**
* Gets the detailed description of a scan in JSON format.
*
* @param scanId The id of the scan to retrieve the description.
* @return JSONObject The detailed description in JSON.
*/
public JSONObject getScanDetails(String scanId) throws IOException, JSONException;
/**
* Gets the {@link IAuthenticationProvider} used to authenticate with a scanning service.
*
* @return
*/
public IAuthenticationProvider getAuthenticationProvider();
/**
* Sets the {@link IProgress} used to record status messages.
* @param progress The {@link IProgress}.
*/
public void setProgress(IProgress progress);
}