From 00cf9b1de90455b651f117622620d2757fe0f76d Mon Sep 17 00:00:00 2001 From: mariofalonso Date: Mon, 9 Jan 2023 12:28:36 +0100 Subject: [PATCH] Added --no-module-downloads --- package.json | 5 +++++ src/tfsec_wrapper.ts | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/package.json b/package.json index ca08f95..fb85c30 100644 --- a/package.json +++ b/package.json @@ -45,6 +45,11 @@ "default": "true", "description": "Don't include results from downloaded modules. (Still scanned, just not included in the results)" }, + "tfsec.noModuleDownloads": { + "type": "boolean", + "default": "true", + "description": "Do not download remote modules" + }, "tfsec.fullDepthSearch": { "type": "boolean", "default": "true", diff --git a/src/tfsec_wrapper.ts b/src/tfsec_wrapper.ts index 2ea142b..50a9d57 100644 --- a/src/tfsec_wrapper.ts +++ b/src/tfsec_wrapper.ts @@ -158,10 +158,15 @@ export class TfsecWrapper { if (config.get('fullDepthSearch')) { command.push('--force-all-dirs'); } + if (config.get('ignoreDownloadedModules')) { command.push('--exclude-downloaded-modules'); } + if (config.get('noModuleDownloads')) { + command.push('--no-module-downloads'); + } + if (config.get('debug')) { command.push('--verbose'); }