Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/main/wrapper/CxConstants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ export enum CxConstants {
AI_GUIDED_REMEDIATION_KEY = "scan.config.plugins.aiGuidedRemediation",
STANDALONE_KEY = "scan.config.plugins.cxdevassist",
ASSIST_KEY = "scan.config.plugins.cxoneassist",
DAST_ENABLED_KEY = "scan.config.plugins.dastenabled",
AI_MCP_SERVER_KEY = "scan.config.plugins.aiMcpServer",
TELEMETRY = "telemetry",
SUB_CMD_TELEMETRY_AI = "ai",
Expand Down
13 changes: 12 additions & 1 deletion src/main/wrapper/CxWrapper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -512,6 +512,17 @@ export class CxWrapper {
return value?.toLowerCase() === "true";
}

async dastEnabled(): Promise<boolean> {
const commands: string[] = [CxConstants.CMD_UTILS, CxConstants.SUB_CMD_TENANT];
commands.push(...this.initializeCommands(false));

const exec = new ExecutionService();
const output = await exec.executeMapTenantOutputCommands(this.config.pathToExecutable, commands);

const value = getTrimmedMapValue(output, CxConstants.DAST_ENABLED_KEY);
return value?.toLowerCase() === "true";
}

async aiMcpServerEnabled(): Promise<boolean> {
const commands: string[] = [CxConstants.CMD_UTILS, CxConstants.SUB_CMD_TENANT];
commands.push(...this.initializeCommands(false));
Expand Down Expand Up @@ -651,4 +662,4 @@ export class CxWrapper {
}
return r;
}
}
}
Loading