@coana-tech/cli 14.12.193 → 14.12.194

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/cli.mjs CHANGED
@@ -234276,6 +234276,118 @@ function assertDefined(value2) {
234276
234276
  return value2;
234277
234277
  }
234278
234278
 
234279
+ // dist/internal/validate-external-dependencies.js
234280
+ async function validateExternalDependencies(ecosystems, command, manifestFileNames) {
234281
+ const checks = [];
234282
+ const ecosystemSet = new Set(ecosystems);
234283
+ if (ecosystemSet.has("NPM")) {
234284
+ checks.push(...getNpmChecks(command, manifestFileNames));
234285
+ }
234286
+ if (ecosystemSet.has("PIP")) {
234287
+ checks.push(...getPipChecks(command, manifestFileNames));
234288
+ }
234289
+ if (ecosystemSet.has("MAVEN") && command === "run") {
234290
+ checks.push(checkJavaAvailable());
234291
+ }
234292
+ if (ecosystemSet.has("GO")) {
234293
+ checks.push(checkTool("go", "Go (GO)", "Required for Go module management. Install from https://go.dev/dl/"));
234294
+ }
234295
+ if (ecosystemSet.has("NUGET") && command === "run") {
234296
+ checks.push(checkTool("dotnet", ".NET (NUGET)", "Required for .NET analysis. Install from https://dotnet.microsoft.com/download"));
234297
+ }
234298
+ if (ecosystemSet.has("RUST") && command === "compute-fixes-and-upgrade-purls") {
234299
+ checks.push(checkTool("cargo", "Rust (RUST)", "Required for Rust dependency management. Install from https://rustup.rs"));
234300
+ }
234301
+ if (ecosystemSet.has("RUBYGEMS") && command === "compute-fixes-and-upgrade-purls") {
234302
+ checks.push(checkEitherTool("bundle", "bundler", "Ruby (RUBYGEMS)", "bundle (or bundler)", "Required for Ruby dependency management. Install from https://bundler.io"));
234303
+ }
234304
+ const results = await Promise.all(checks);
234305
+ const missing = results.filter((r3) => r3 !== null);
234306
+ if (missing.length > 0) {
234307
+ const grouped = /* @__PURE__ */ new Map();
234308
+ for (const m4 of missing) {
234309
+ if (!grouped.has(m4.ecosystem))
234310
+ grouped.set(m4.ecosystem, []);
234311
+ grouped.get(m4.ecosystem).push(m4);
234312
+ }
234313
+ let message2 = "Missing required external tools for the detected project ecosystems:\n";
234314
+ for (const [ecosystem, tools] of grouped) {
234315
+ message2 += `
234316
+ ${ecosystem}:
234317
+ `;
234318
+ for (const tool of tools) {
234319
+ message2 += ` - ${tool.tool}: ${tool.message}
234320
+ `;
234321
+ }
234322
+ }
234323
+ message2 += "\nInstall the missing tools and try again.";
234324
+ throw new Error(message2);
234325
+ }
234326
+ }
234327
+ function getNpmChecks(command, manifestFileNames) {
234328
+ const checks = [];
234329
+ const nexe = isNexeMode();
234330
+ if (command === "run") {
234331
+ if (!nexe) {
234332
+ checks.push(checkTool("npm", "NPM", "Required for NPM dependency management. Install from https://nodejs.org"));
234333
+ }
234334
+ } else {
234335
+ const files = manifestFileNames ?? [];
234336
+ if (files.some((f6) => f6.endsWith("package-lock.json")) && !nexe) {
234337
+ checks.push(checkTool("npm", "NPM", "Required for NPM dependency management. Install from https://nodejs.org"));
234338
+ }
234339
+ if (files.some((f6) => f6.endsWith("pnpm-lock.yaml"))) {
234340
+ checks.push(checkTool("pnpm", "NPM", "Required for pnpm dependency management. Install from https://pnpm.io"));
234341
+ }
234342
+ if (files.some((f6) => f6.endsWith("yarn.lock"))) {
234343
+ checks.push(checkTool("yarn", "NPM", "Required for Yarn dependency management. Install from https://yarnpkg.com"));
234344
+ }
234345
+ }
234346
+ return checks;
234347
+ }
234348
+ function getPipChecks(command, manifestFileNames) {
234349
+ const checks = [];
234350
+ const nexe = isNexeMode();
234351
+ if (command === "run") {
234352
+ checks.push(checkEitherTool("python3", "python", "Python (PIP)", "python3 (or python)", "Required for Python dependency management. Install from https://python.org"));
234353
+ if (!nexe) {
234354
+ checks.push(checkTool("uv", "Python (PIP)", "Required for Python dependency management. Install from https://docs.astral.sh/uv/"));
234355
+ }
234356
+ } else {
234357
+ const files = manifestFileNames ?? [];
234358
+ if (files.some((f6) => f6.endsWith("uv.lock")) && !nexe) {
234359
+ checks.push(checkTool("uv", "Python (PIP)", "Required for Python dependency management. Install from https://docs.astral.sh/uv/"));
234360
+ }
234361
+ }
234362
+ return checks;
234363
+ }
234364
+ async function checkTool(command, ecosystem, message2) {
234365
+ const available = await isCommandAvailable(command);
234366
+ if (!available) {
234367
+ return { ecosystem, tool: command, message: message2 };
234368
+ }
234369
+ return null;
234370
+ }
234371
+ async function checkEitherTool(command1, command2, ecosystem, toolLabel, message2) {
234372
+ const [avail1, avail2] = await Promise.all([isCommandAvailable(command1), isCommandAvailable(command2)]);
234373
+ if (!avail1 && !avail2) {
234374
+ return { ecosystem, tool: toolLabel, message: message2 };
234375
+ }
234376
+ return null;
234377
+ }
234378
+ var JAVA_HOME_ENV_VARS = ["JAVA_HOME", "JAVA8_HOME", "JAVA11_HOME", "JAVA17_HOME", "JAVA21_HOME"];
234379
+ async function checkJavaAvailable() {
234380
+ if (await isCommandAvailable("java"))
234381
+ return null;
234382
+ if (JAVA_HOME_ENV_VARS.some((v) => process.env[v]))
234383
+ return null;
234384
+ return {
234385
+ ecosystem: "Maven (MAVEN)",
234386
+ tool: "java",
234387
+ message: "Required for Java/Maven analysis. Install a JDK from https://adoptium.net"
234388
+ };
234389
+ }
234390
+
234279
234391
  // dist/cli-upgrade-purl.js
234280
234392
  var UpgradePurlPartialError = class extends Error {
234281
234393
  subprojectResults;
@@ -234332,6 +234444,10 @@ ${Array.from(upgrades).map(([idx, upgradeVersion]) => ` ${prettyPrintPurlUpgrade
234332
234444
  }
234333
234445
  ecosystemToSocketArtifactUpgrades.get(ecosystem).set(idx, upgradeVersion);
234334
234446
  }
234447
+ const detectedEcosystems = Array.from(ecosystemToSocketArtifactUpgrades.keys());
234448
+ if (!options.disableExternalToolChecks) {
234449
+ await validateExternalDependencies(detectedEcosystems, "compute-fixes-and-upgrade-purls", manifestFiles);
234450
+ }
234335
234451
  let anyErrors = false;
234336
234452
  let anySkipped = false;
234337
234453
  const subprojectResults = /* @__PURE__ */ new Map();
@@ -234593,7 +234709,8 @@ async function computeFixesAndUpgradePurls(path9, options, logFile) {
234593
234709
  concurrency: "1",
234594
234710
  include: options.include,
234595
234711
  exclude: options.exclude,
234596
- rangeStyle: options.rangeStyle
234712
+ rangeStyle: options.rangeStyle,
234713
+ disableExternalToolChecks: options.disableExternalToolChecks
234597
234714
  }, autofixRunId) ?? "fixed-all";
234598
234715
  if (autofixRunId) {
234599
234716
  const allGhsasFailed = fixesFound.length === 0;
@@ -251523,7 +251640,7 @@ async function onlineScan(dependencyTree, apiKey, timeout) {
251523
251640
  }
251524
251641
 
251525
251642
  // dist/version.js
251526
- var version3 = "14.12.193";
251643
+ var version3 = "14.12.194";
251527
251644
 
251528
251645
  // dist/cli-core.js
251529
251646
  var { mapValues, omit, partition, pickBy: pickBy2 } = import_lodash15.default;
@@ -251732,6 +251849,10 @@ var CliCore = class {
251732
251849
  this.sendProgress("SCAN_FOR_VULNERABILITIES", true, ".", ".");
251733
251850
  const { artifacts, ecosystemToWorkspaceToAnalysisData, ecosystemToWorkspaceToVulnerabilities } = await fetchArtifactsFromSocket(this.rootWorkingDirectory, this.options.manifestsTarHash, "reachability", this.options.useUnreachableFromPrecomputation, this.options.useOnlyPregeneratedSboms);
251734
251851
  this.sendProgress("SCAN_FOR_VULNERABILITIES", false, ".", ".");
251852
+ const detectedEcosystemsSocket = Object.keys(ecosystemToWorkspaceToAnalysisData);
251853
+ if (!this.options.disableExternalToolChecks) {
251854
+ await validateExternalDependencies(detectedEcosystemsSocket, "run");
251855
+ }
251735
251856
  const subProjects = Object.entries(ecosystemToWorkspaceToAnalysisData).flatMap(([ecosystem, workspaceToAnalysisData]) => {
251736
251857
  return Object.entries(workspaceToAnalysisData).map(([workspace, analysisData]) => {
251737
251858
  return {
@@ -251873,6 +251994,10 @@ var CliCore = class {
251873
251994
  const manager = await ProjectManager.create(this.rootWorkingDirectory, otherModulesCommunicator, this.options.ecosystems, this.options.includeDirs, this.options.excludeDirs, this.options.changedFiles);
251874
251995
  this.sendProgress("CREATE_PROJECT_MANAGER", false);
251875
251996
  const { reachabilitySupport, traditionalScaSupport, noSupport } = manager.getSubprojectsWithWorkspacePaths();
251997
+ const detectedEcosystemsSbom = [...new Set([...reachabilitySupport, ...traditionalScaSupport].map((s6) => s6.ecosystem))];
251998
+ if (!this.options.disableExternalToolChecks) {
251999
+ await validateExternalDependencies(detectedEcosystemsSbom, "run");
252000
+ }
251876
252001
  await this.dashboardAPI.registerSubprojects([...reachabilitySupport, ...traditionalScaSupport, ...noSupport].map((sp) => ({
251877
252002
  ...sp,
251878
252003
  subprojectPath: relative21(this.rootWorkingDirectory, sp.subprojectPath) || "."
@@ -252532,7 +252657,7 @@ async function writeAnalysisDebugInfo(outputFilePath, ecosystemToWorkspaceToVuln
252532
252657
  handleNexeBinaryMode();
252533
252658
  var program2 = new Command();
252534
252659
  var run2 = new Command();
252535
- run2.name("run").argument("<path>", "File system path to folder containing the project").option("-o, --output-dir <path>", "Write json report to <path>/coana-report.json").option("-d, --debug", "Enable debug logging", false).option("-s, --silent", "Silence all debug/warning output", false).option("--silent-spinner", "Silence spinner", "CI" in process.env || !process.stdin.isTTY).option("-p, --print-report", "Print the report to the console", false).option("--offline-database <path>", "Path to a coana-offline-db.json file for running the CLI without internet connectivity", void 0).option("-t, --timeout <timeout>", "Set API <timeout> in milliseconds to Coana backend.", "300000").option("-a, --analysis-timeout <timeout>", "Set <timeout> in seconds for each reachability analysis run").option("--memory-limit <memoryInMB>", "Set memory limit for analysis to <memoryInMB> megabytes of memory.", "8192").option("-c, --concurrency <concurrency>", "Set the maximum number of concurrent reachability analysis runs. It's recommended to choose a concurrency level that ensures that each analysis run has at least the --memory-limit amount of memory available. NPM reachability analysis does not support concurrent execution, so the concurrency level is ignored for NPM.", "1").option("--api-key <key>", "Set the Coana dashboard API key. By setting you also enable the dashboard integration.").addOption(new Option("--write-report-to-file", "Write the report dashboard-compatible report to dashboard-report.json. This report may help the Coana team debug issues with the report insertion mechanism.").default(false).hideHelp()).option("--project-name <repoName>", "Set the name of the repository. Used for dashboard integration.").option("--repo-url <repoUrl>", "Set the URL of the repository. Used for dashboard integration.").option("--include-dirs <relativeDirs...>", "globs for directories to include from the detection of subprojects (space-separated)(use relative paths from the project root). Notice, projects that are not included may still be scanned if they are referenced from included projects.").option("--exclude-dirs <relativeDirs...>", "globs for directories to exclude from the detection of subprojects (space-separated)(use relative paths from the project root). Notice, excluded projects may still be scanned if they are referenced from non-excluded projects.").option("--disable-analysis-splitting", "Limits Coana to at most 1 reachability analysis run per workspace").option("--print-analysis-log-file", "Store log output from the JavaScript/TypeScript reachability analysis in the file js-analysis.log file in the root of each workspace", false).option("--entry-points <entryPoints...>", "List of files to analyze for root workspace. The reachability analysis automatically analyzes all files used by the entry points. If not provided, all JavaScript and TypeScript files are considered entry points. For non-root workspaces, all JavaScript and TypeScript files are analyzed as well.").option("--include-projects-with-no-reachability-support", "Also runs Coana on projects where we support traditional SCA, but does not yet support reachability analysis.", false).option("--ecosystems <ecosystems...>", "List of ecosystems to analyze (space-separated). Currently NPM, PIP, MAVEN, NUGET and GO are supported. Default is all supported ecosystems.").addOption(new Option("--purl-types <purlTypes...>", "List of PURL types to analyze (space-separated). Currently npm, pypi, maven, nuget, golang and cargo are supported. Default is all supported purl types.").hideHelp()).option("--changed-files <files...>", "List of files that have changed. If provided, Coana only analyzes workspaces and modules that contain changed files.").option("--disable-report-submission", "Disable the submission of the report to the Coana dashboard. Used by the pipeline blocking feature.", false).option("--disable-analytics-sharing", "Disable analytics sharing.", false).option("--provider-project <path>", "File system path to folder containing the provider project (Only supported for Maven, Gradle, and SBT)").option("--provider-workspaces <dirs...>", "List of workspaces that build the provided runtime environment (Only supported for Maven, Gradle, and SBT)", (paths) => paths.split(" ")).option("--lightweight-reachability", "Runs Coana in lightweight mode. This increases analysis speed but also raises the risk of Coana misclassifying the reachability of certain complex vulnerabilities. Recommended only for use with Coana Guardrail mode.", false).addOption(new Option("--run-without-docker", "Run package managers and reachability analyzers without using docker").default(process.env.RUN_WITHOUT_DOCKER === "true").hideHelp()).addOption(new Option("--run-env <env>", "Specifies the environment in which the CLI is run. So far only MANAGED_SCAN and UNKNOWN are supported.").default("UNKNOWN").choices(["UNKNOWN", "MANAGED_SCAN"]).hideHelp()).addOption(new Option("--guardrail-mode", "Run Coana in guardrail mode. This mode is used to prevent new reachable vulnerabilities from being introduced into the codebase. Usually run as a CI check when pushing new commits to a pull request.")).option("--ignore-failing-workspaces", "Continue processing when a workspace fails instead of exiting. Failed workspaces will be logged at termination.", false).addOption(new Option("--socket-mode <output-file>", "Run Coana in socket mode and write report to <output-file>").hideHelp()).addOption(new Option("--manifests-tar-hash <hash>", "Hash of the tarball containing all manifest files already uploaded to Socket. If provided, Socket will be used for computing dependency trees.").hideHelp()).option("--skip-cache-usage", "Do not attempt to use cached analysis configuration from previous runs", false).addOption(new Option("--lazy-mode", "Enable lazy analysis mode for JavaScript/TypeScript. This can significantly speed up analysis by only analyzing code that is actually relevant for the vulnerabilities being analyzed.").default(false).hideHelp()).addOption(new Option("--min-severity <severity>", "Set the minimum severity of vulnerabilities to analyze. Supported severities are info, low, moderate, high and critical.").choices(["info", "INFO", "low", "LOW", "moderate", "MODERATE", "high", "HIGH", "critical", "CRITICAL"])).option("--use-unreachable-from-precomputation", "Skip the reachability analysis for vulnerabilities that are already known to be unreachable from the precomputed reachability analysis (Tier 2).", false).addOption(new Option("--use-only-pregenerated-sboms", "Only include artifacts that have CDX or SPDX files in their manifest files.").default(false).hideHelp()).version(version3).configureHelp({ sortOptions: true }).action(async (path9, options) => {
252660
+ run2.name("run").argument("<path>", "File system path to folder containing the project").option("-o, --output-dir <path>", "Write json report to <path>/coana-report.json").option("-d, --debug", "Enable debug logging", false).option("-s, --silent", "Silence all debug/warning output", false).option("--silent-spinner", "Silence spinner", "CI" in process.env || !process.stdin.isTTY).option("-p, --print-report", "Print the report to the console", false).option("--offline-database <path>", "Path to a coana-offline-db.json file for running the CLI without internet connectivity", void 0).option("-t, --timeout <timeout>", "Set API <timeout> in milliseconds to Coana backend.", "300000").option("-a, --analysis-timeout <timeout>", "Set <timeout> in seconds for each reachability analysis run").option("--memory-limit <memoryInMB>", "Set memory limit for analysis to <memoryInMB> megabytes of memory.", "8192").option("-c, --concurrency <concurrency>", "Set the maximum number of concurrent reachability analysis runs. It's recommended to choose a concurrency level that ensures that each analysis run has at least the --memory-limit amount of memory available. NPM reachability analysis does not support concurrent execution, so the concurrency level is ignored for NPM.", "1").option("--api-key <key>", "Set the Coana dashboard API key. By setting you also enable the dashboard integration.").addOption(new Option("--write-report-to-file", "Write the report dashboard-compatible report to dashboard-report.json. This report may help the Coana team debug issues with the report insertion mechanism.").default(false).hideHelp()).option("--project-name <repoName>", "Set the name of the repository. Used for dashboard integration.").option("--repo-url <repoUrl>", "Set the URL of the repository. Used for dashboard integration.").option("--include-dirs <relativeDirs...>", "globs for directories to include from the detection of subprojects (space-separated)(use relative paths from the project root). Notice, projects that are not included may still be scanned if they are referenced from included projects.").option("--exclude-dirs <relativeDirs...>", "globs for directories to exclude from the detection of subprojects (space-separated)(use relative paths from the project root). Notice, excluded projects may still be scanned if they are referenced from non-excluded projects.").option("--disable-analysis-splitting", "Limits Coana to at most 1 reachability analysis run per workspace").option("--print-analysis-log-file", "Store log output from the JavaScript/TypeScript reachability analysis in the file js-analysis.log file in the root of each workspace", false).option("--entry-points <entryPoints...>", "List of files to analyze for root workspace. The reachability analysis automatically analyzes all files used by the entry points. If not provided, all JavaScript and TypeScript files are considered entry points. For non-root workspaces, all JavaScript and TypeScript files are analyzed as well.").option("--include-projects-with-no-reachability-support", "Also runs Coana on projects where we support traditional SCA, but does not yet support reachability analysis.", false).option("--ecosystems <ecosystems...>", "List of ecosystems to analyze (space-separated). Currently NPM, PIP, MAVEN, NUGET and GO are supported. Default is all supported ecosystems.").addOption(new Option("--purl-types <purlTypes...>", "List of PURL types to analyze (space-separated). Currently npm, pypi, maven, nuget, golang and cargo are supported. Default is all supported purl types.").hideHelp()).option("--changed-files <files...>", "List of files that have changed. If provided, Coana only analyzes workspaces and modules that contain changed files.").option("--disable-report-submission", "Disable the submission of the report to the Coana dashboard. Used by the pipeline blocking feature.", false).option("--disable-analytics-sharing", "Disable analytics sharing.", false).option("--provider-project <path>", "File system path to folder containing the provider project (Only supported for Maven, Gradle, and SBT)").option("--provider-workspaces <dirs...>", "List of workspaces that build the provided runtime environment (Only supported for Maven, Gradle, and SBT)", (paths) => paths.split(" ")).option("--lightweight-reachability", "Runs Coana in lightweight mode. This increases analysis speed but also raises the risk of Coana misclassifying the reachability of certain complex vulnerabilities. Recommended only for use with Coana Guardrail mode.", false).addOption(new Option("--run-without-docker", "Run package managers and reachability analyzers without using docker").default(process.env.RUN_WITHOUT_DOCKER === "true").hideHelp()).addOption(new Option("--run-env <env>", "Specifies the environment in which the CLI is run. So far only MANAGED_SCAN and UNKNOWN are supported.").default("UNKNOWN").choices(["UNKNOWN", "MANAGED_SCAN"]).hideHelp()).addOption(new Option("--guardrail-mode", "Run Coana in guardrail mode. This mode is used to prevent new reachable vulnerabilities from being introduced into the codebase. Usually run as a CI check when pushing new commits to a pull request.")).option("--ignore-failing-workspaces", "Continue processing when a workspace fails instead of exiting. Failed workspaces will be logged at termination.", false).addOption(new Option("--socket-mode <output-file>", "Run Coana in socket mode and write report to <output-file>").hideHelp()).addOption(new Option("--manifests-tar-hash <hash>", "Hash of the tarball containing all manifest files already uploaded to Socket. If provided, Socket will be used for computing dependency trees.").hideHelp()).option("--skip-cache-usage", "Do not attempt to use cached analysis configuration from previous runs", false).addOption(new Option("--lazy-mode", "Enable lazy analysis mode for JavaScript/TypeScript. This can significantly speed up analysis by only analyzing code that is actually relevant for the vulnerabilities being analyzed.").default(false).hideHelp()).addOption(new Option("--min-severity <severity>", "Set the minimum severity of vulnerabilities to analyze. Supported severities are info, low, moderate, high and critical.").choices(["info", "INFO", "low", "LOW", "moderate", "MODERATE", "high", "HIGH", "critical", "CRITICAL"])).option("--use-unreachable-from-precomputation", "Skip the reachability analysis for vulnerabilities that are already known to be unreachable from the precomputed reachability analysis (Tier 2).", false).addOption(new Option("--use-only-pregenerated-sboms", "Only include artifacts that have CDX or SPDX files in their manifest files.").default(false).hideHelp()).option("--disable-external-tool-checks", "Disable validation of external tools (npm, python, go, etc.) before running analysis.", false).version(version3).configureHelp({ sortOptions: true }).action(async (path9, options) => {
252536
252661
  process.env.DOCKER_IMAGE_TAG ??= version3;
252537
252662
  options.ecosystems = options.ecosystems?.map((e) => e.toUpperCase());
252538
252663
  options.minSeverity = options.minSeverity?.toUpperCase();
@@ -252546,7 +252671,7 @@ applyFixes.name("apply-fixes").argument("<path>", "File system path to the folde
252546
252671
  await applyFix(path9, fixIds, options);
252547
252672
  }).configureHelp({ sortOptions: true });
252548
252673
  var computeFixesAndUpgradePurlsCmd = new Command();
252549
- computeFixesAndUpgradePurlsCmd.name("compute-fixes-and-upgrade-purls").argument("<path>", "File system path to the folder containing the project").option("-a, --apply-fixes-to <ghsas...>", 'GHSA IDs to compute fixes for. Use "all" to compute fixes for all vulnerabilities.', []).option("--dry-run", "Show what changes would be made without actually making them", false).option("-i, --include <patterns...>", "Glob patterns to include workspaces").option("-e, --exclude <patterns...>", "Glob patterns to exclude workspaces").option("-d, --debug", "Enable debug logging", false).option("-s, --silent", "Silence all debug/warning output", false).option("--silent-spinner", "Silence spinner", "CI" in process.env || !process.stdin.isTTY).option("--range-style <style>", 'Range style to use for the output. Currently only "pin" is supported and it only works for npm.').option("--disable-major-updates", "Do not suggest major updates. If only major update are available, the fix will not be applied.", false).option("-o, --output-file <file>", "Writes output to a JSON file").option("--minimum-release-age <minimumReleaseAge>", "Do not allow upgrades to package versions that are newer than minimumReleaseAge. Format is 2m, 5h, 3d or 1w").option("--show-affected-direct-dependencies", "Show the affected direct dependencies for each vulnerability and what upgrades could fix them - does not apply the upgrades.", false).option("--purl-types <purlTypes...>", "List of PURL types to filter artifacts by (space-separated). Only vulnerabilities from artifacts matching these types will be included.").addOption(new Option("--run-without-docker", "Run package managers without using docker").default(process.env.RUN_WITHOUT_DOCKER === "true").hideHelp()).addOption(new Option("--manifests-tar-hash <hash>", "Hash of the tarball containing all manifest files already uploaded to Socket. If provided, Socket will be used for computing dependency trees.").hideHelp()).version(version3).action(async (path9, options) => {
252674
+ computeFixesAndUpgradePurlsCmd.name("compute-fixes-and-upgrade-purls").argument("<path>", "File system path to the folder containing the project").option("-a, --apply-fixes-to <ghsas...>", 'GHSA IDs to compute fixes for. Use "all" to compute fixes for all vulnerabilities.', []).option("--dry-run", "Show what changes would be made without actually making them", false).option("-i, --include <patterns...>", "Glob patterns to include workspaces").option("-e, --exclude <patterns...>", "Glob patterns to exclude workspaces").option("-d, --debug", "Enable debug logging", false).option("-s, --silent", "Silence all debug/warning output", false).option("--silent-spinner", "Silence spinner", "CI" in process.env || !process.stdin.isTTY).option("--range-style <style>", 'Range style to use for the output. Currently only "pin" is supported and it only works for npm.').option("--disable-major-updates", "Do not suggest major updates. If only major update are available, the fix will not be applied.", false).option("-o, --output-file <file>", "Writes output to a JSON file").option("--minimum-release-age <minimumReleaseAge>", "Do not allow upgrades to package versions that are newer than minimumReleaseAge. Format is 2m, 5h, 3d or 1w").option("--show-affected-direct-dependencies", "Show the affected direct dependencies for each vulnerability and what upgrades could fix them - does not apply the upgrades.", false).option("--purl-types <purlTypes...>", "List of PURL types to filter artifacts by (space-separated). Only vulnerabilities from artifacts matching these types will be included.").addOption(new Option("--run-without-docker", "Run package managers without using docker").default(process.env.RUN_WITHOUT_DOCKER === "true").hideHelp()).addOption(new Option("--manifests-tar-hash <hash>", "Hash of the tarball containing all manifest files already uploaded to Socket. If provided, Socket will be used for computing dependency trees.").hideHelp()).option("--disable-external-tool-checks", "Disable validation of external tools (npm, python, go, etc.) before running analysis.", false).version(version3).action(async (path9, options) => {
252550
252675
  checkNotWindows();
252551
252676
  process.env.DOCKER_IMAGE_TAG ??= version3;
252552
252677
  if (options.outputFile && !options.outputFile.endsWith(".json")) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@coana-tech/cli",
3
- "version": "14.12.193",
3
+ "version": "14.12.194",
4
4
  "description": "Coana CLI",
5
5
  "type": "module",
6
6
  "bin": {