praxis-sec 1.2.0 → 1.2.2
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/assets/praxis-architecture.svg +304 -0
- package/assets/praxis-logo.svg +38 -0
- package/cli/agents/abom-generator.js +1 -1
- package/cli/agents/agent-attestation-agent.js +10 -1
- package/cli/agents/agent-config-scanner.js +1 -1
- package/cli/agents/ai-infra-inventory-agent.js +482 -482
- package/cli/agents/base-agent.js +1 -1
- package/cli/agents/endpoint-agent-abuse-agent.js +1 -1
- package/cli/agents/html-reporter.js +10 -10
- package/cli/agents/index.js +2 -2
- package/cli/agents/injection-tester.js +8 -1
- package/cli/agents/mcp-security-agent.js +600 -594
- package/cli/agents/memory-poisoning-agent.js +1 -1
- package/cli/agents/model-file-scanner.js +1 -1
- package/cli/agents/orchestrator.js +375 -355
- package/cli/agents/prompt-injection-prober.js +228 -228
- package/cli/bin/praxis.js +7 -3
- package/cli/commands/agent-fix.js +1091 -1245
- package/cli/commands/audit.js +1232 -1216
- package/cli/commands/baseline.js +3 -2
- package/cli/commands/benchmark.js +1 -1
- package/cli/commands/ci.js +50 -25
- package/cli/commands/deps.js +11 -5
- package/cli/commands/diff.js +2 -1
- package/cli/commands/env-audit.js +1 -1
- package/cli/commands/fix.js +1 -1
- package/cli/commands/legal.js +2 -1
- package/cli/commands/mcp.js +3 -2
- package/cli/commands/openclaw.js +3 -6
- package/cli/commands/red-team.js +351 -350
- package/cli/commands/remediate.js +1 -1
- package/cli/commands/rotate.js +1 -1
- package/cli/commands/rules.js +1 -1
- package/cli/commands/scan-standard.js +3 -6
- package/cli/commands/scan.js +554 -554
- package/cli/commands/score.js +1 -1
- package/cli/commands/undo.js +22 -77
- package/cli/commands/vibe-check.js +3 -2
- package/cli/commands/watch.js +6 -5
- package/cli/core/fix-plan.js +274 -0
- package/cli/core/fs.js +27 -0
- package/cli/core/git-clone.js +8 -6
- package/cli/core/glob.js +56 -0
- package/cli/core/output/html-theme.js +158 -158
- package/cli/core/output/json.js +56 -48
- package/cli/core/output/sarif.js +2 -2
- package/cli/core/paths.js +91 -0
- package/cli/core/web/jobs.js +2 -2
- package/cli/core/web/server.js +19 -8
- package/cli/data/threatpacks/latest.json +41 -41
- package/cli/integrations/github-action.js +136 -0
- package/cli/utils/cache-manager.js +2 -1
- package/cli/utils/plugin-loader.js +15 -95
- package/cli/utils/rule-import.js +227 -227
- package/cli/utils/rule-registry.js +425 -425
- package/cli/utils/scan-fingerprint.js +1 -1
- package/cli/utils/score-history.js +118 -118
- package/docs/USAGE.md +16 -9
- package/docs/design/WEB-UI.md +4 -5
- package/package.json +81 -71
|
@@ -38,7 +38,7 @@ import { execSync, execFileSync } from 'child_process';
|
|
|
38
38
|
import chalk from 'chalk';
|
|
39
39
|
import ora from 'ora';
|
|
40
40
|
import writeFileAtomic from 'write-file-atomic';
|
|
41
|
-
import fg from '
|
|
41
|
+
import fg from '../core/glob.js';
|
|
42
42
|
import {
|
|
43
43
|
SECRET_PATTERNS,
|
|
44
44
|
SKIP_DIRS,
|
package/cli/commands/rotate.js
CHANGED
package/cli/commands/rules.js
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
* The manifest is the important half. A bundle without it would imply Praxis is
|
|
9
9
|
* nothing but its patterns; the manifest names the layers that have no Semgrep
|
|
10
10
|
* equivalent (AST/taint, the probe corpus, entropy heuristics). See
|
|
11
|
-
* docs/
|
|
11
|
+
* docs/USAGE.md.
|
|
12
12
|
*/
|
|
13
13
|
|
|
14
14
|
import path from 'path';
|
|
@@ -16,6 +16,7 @@ import fs from 'fs';
|
|
|
16
16
|
import path from 'path';
|
|
17
17
|
import chalk from 'chalk';
|
|
18
18
|
import ora from 'ora';
|
|
19
|
+
import { displayPath } from '../core/paths.js';
|
|
19
20
|
import { buildOrchestratorAsync } from '../agents/index.js';
|
|
20
21
|
import { ScoringEngine } from '../agents/scoring-engine.js';
|
|
21
22
|
import {
|
|
@@ -102,11 +103,7 @@ export async function scanStandardCommand(name, targetPath = '.', options = {})
|
|
|
102
103
|
controls: standardSummary.controls,
|
|
103
104
|
findings: filtered.map(f => ({
|
|
104
105
|
...f,
|
|
105
|
-
file:
|
|
106
|
-
.replace(/\\/g, '/')
|
|
107
|
-
.replace(/^[a-zA-Z]:\/+/, '')
|
|
108
|
-
.replace(/^.*\/Praxis\/showcase-target\//, 'showcase-target/')
|
|
109
|
-
.replace(/^.*\/Praxis\//, ''),
|
|
106
|
+
file: displayPath(f.file, absolutePath),
|
|
110
107
|
})),
|
|
111
108
|
score: scoreResult.score,
|
|
112
109
|
grade: scoreResult.grade?.letter || 'A',
|
|
@@ -239,7 +236,7 @@ async function printHumanReport(standard, report) { console.log(chalk.white.bol
|
|
|
239
236
|
const sev = (f.severity || 'medium').toUpperCase();
|
|
240
237
|
const color = SEV_COLORS[f.severity] || chalk.white;
|
|
241
238
|
const tag = ids.join(', ');
|
|
242
|
-
const file = f.file ?
|
|
239
|
+
const file = f.file ? displayPath(f.file, process.cwd()) : '';
|
|
243
240
|
const loc = file ? `${file}:${f.line || 0}` : '';
|
|
244
241
|
console.log(` ${color(`[${sev}]`)} ${chalk.cyan(`[${tag}]`)} ${f.title || f.rule || ''}`);
|
|
245
242
|
if (loc) console.log(chalk.gray(` ${loc}`));
|