|
13 | 13 | import com.fasterxml.jackson.databind.ObjectMapper; |
14 | 14 | import com.fasterxml.jackson.databind.type.CollectionType; |
15 | 15 | import com.fasterxml.jackson.databind.type.TypeFactory; |
16 | | -import jdk.nashorn.internal.runtime.regexp.joni.ast.StringNode; |
17 | 16 | import lombok.NonNull; |
18 | 17 | import org.apache.commons.lang3.StringUtils; |
19 | 18 | import org.slf4j.Logger; |
20 | 19 | import org.slf4j.LoggerFactory; |
| 20 | + |
21 | 21 | import java.io.IOException; |
22 | 22 | import java.nio.file.Files; |
23 | | -import java.util.*; |
| 23 | +import java.util.ArrayList; |
| 24 | +import java.util.List; |
| 25 | +import java.util.Map; |
| 26 | +import java.util.UUID; |
24 | 27 |
|
25 | 28 | public class CxWrapper { |
26 | 29 |
|
@@ -284,20 +287,19 @@ private List<String> buildResultsArgumentsArray(UUID scanId, ReportFormat report |
284 | 287 | return arguments; |
285 | 288 | } |
286 | 289 |
|
287 | | - public String scaRemediation(String packageFile, String packages, String packageVersion) throws CxException, IOException, InterruptedException { |
| 290 | + public String scaRemediation(String packageFiles, String packages, String packageVersion) throws CxException, IOException, InterruptedException { |
288 | 291 | List<String> arguments = new ArrayList<>(); |
289 | 292 | arguments.add(CxConstants.CMD_UTILS); |
290 | 293 | arguments.add(CxConstants.CMD_REMEDIATION); |
291 | 294 | arguments.add(CxConstants.SUB_CMD_REMEDIATION_SCA); |
292 | | - arguments.add(CxConstants.SCA_REMEDIATION_PACKAGE_FILE); |
293 | | - arguments.add(packageFile); |
| 295 | + arguments.add(CxConstants.SCA_REMEDIATION_PACKAGE_FILES); |
| 296 | + arguments.add(packageFiles); |
294 | 297 | arguments.add(CxConstants.SCA_REMEDIATION_PACKAGE); |
295 | 298 | arguments.add(packages); |
296 | 299 | arguments.add(CxConstants.SCA_REMEDIATION_PACKAGE_VERSION); |
297 | 300 | arguments.add(packageVersion); |
298 | 301 |
|
299 | 302 | return Execution.executeCommand(withConfigArguments(arguments), logger, line -> null); |
300 | | - |
301 | 303 | } |
302 | 304 |
|
303 | 305 | public int getResultsBfl(@NonNull UUID scanId, @NonNull String queryId, List<Node> resultNodes) |
|
0 commit comments