agentaudit 3.9.39 → 3.9.40
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 +5 -8
- package/package.json +1 -1
package/cli.mjs
CHANGED
|
@@ -539,20 +539,17 @@ const SKIP_EXTENSIONS = new Set([
|
|
|
539
539
|
'.dylib', '.dll', '.exe', '.bin', '.dat', '.db', '.sqlite',
|
|
540
540
|
'.snap', '.patch', '.diff', '.log', '.csv', '.tsv', '.parquet',
|
|
541
541
|
]);
|
|
542
|
-
// Files that are never security-relevant (
|
|
542
|
+
// Files that are never security-relevant (pure text/metadata only — NO executable files!)
|
|
543
|
+
// Rule: if it CAN execute code (.js, .ts, .mjs, .py etc.), it MUST be scanned.
|
|
544
|
+
// An attacker could hide malware in any executable config file.
|
|
543
545
|
const SKIP_FILES = new Set([
|
|
544
546
|
'license', 'license.md', 'license.txt', 'licence', 'licence.md',
|
|
545
547
|
'changelog.md', 'changelog', 'changes.md', 'history.md',
|
|
546
548
|
'contributing.md', 'contributors.md', 'authors', 'authors.md',
|
|
547
549
|
'code_of_conduct.md', 'security.md', 'funding.yml',
|
|
548
|
-
'.
|
|
549
|
-
'.eslintignore', '.gitignore', '.gitattributes', '.npmignore',
|
|
550
|
+
'.gitignore', '.gitattributes', '.npmignore', '.dockerignore',
|
|
550
551
|
'.editorconfig', '.browserslistrc', '.nvmrc', '.node-version',
|
|
551
|
-
'.
|
|
552
|
-
'jest.config.js', 'jest.config.ts', 'vitest.config.ts', 'vitest.config.js',
|
|
553
|
-
'.babelrc', 'babel.config.js', 'babel.config.json',
|
|
554
|
-
'postcss.config.js', 'postcss.config.mjs', 'tailwind.config.js', 'tailwind.config.ts',
|
|
555
|
-
'prettier.config.js', 'prettier.config.mjs',
|
|
552
|
+
'.prettierignore', '.eslintignore',
|
|
556
553
|
]);
|
|
557
554
|
|
|
558
555
|
function collectFiles(dir, basePath = '', collected = [], totalSize = { bytes: 0 }) {
|