Repository navigation
V2 - #9
Merged
Merged
V2#9
Conversation
Lays the measurement foundation for ASST 2.0: - Fixture corpus of vulnerable/safe PHP samples covering 25 CWEs with inline @expect annotations, plus a small vulnerable and a hardened sample application. - Benchmark harness (npm run bench) reporting precision, recall and F1 per CWE on the fixtures, DVWA (pinned commit) and the NIST SARD PHP Vulnerability Test Suite, with throughput and peak memory. The v1.0 line-based engine results are recorded as the starting baseline. - Install-layout smoke test that recreates the documented XAMPP layout (htdocs/ASST next to htdocs/ProjectFolderToScan) and runs main.js. - CI on Windows, Linux and macOS with Node.js 18/20/22/24 and a benchmark regression gate; nightly full-suite run. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ASST 2.0 engine foundation, keeping the documented installation flow: - core/: command-line options, configuration loader (config.js keys keep their meaning; paths resolve against the ASST folder), single-pass project walker with default exclusion of dependency/VCS folders and .asstignore support, shared file cache, finding model, declarative rule engine, suppressions/baseline, plugin registry, safe execFile helper and ANSI output without prototype extensions. - The existing PHP checks run on the new foundation through a compatibility layer: same results, about 10x faster scans, escaped report output, file:// guide links on every OS, and graceful notes when PHP or the database is not reachable. - Database inspection moved to mysql2 (MySQL 8 auth support) with one connection, escaped identifiers and aggregate queries; stored password hashes are never read, only their length and prefix. - main.js checks the Node.js version first; Node.js 18+ is required. README/index.md: only the Node.js version lines were updated. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ASST 2.0 analysis engine for PHP: - Data-flow (taint) analysis: every PHP file is parsed once (php-parser) and lowered to a small language-independent IR. An abstract interpreter follows request data through variables, arrays, string building, sprintf, functions, methods and classes, with branch joins, loop fixpoints, guard refinement and reachability (exit/return). - Context-aware sinks: SQL quoting, HTML text/attribute/event/script/ URL contexts, shell quoting, LDAP, XPath, file paths, URLs, eval. - Rule registry mapped to OWASP Top 10:2025 (and 2021) and CWE with severity, confidence, trace and snippet; structural rules (execution after redirect, weak password hashing, predictable tokens, loose comparisons, session fixation, XXE options, hard-coded credentials, error disclosure), template/JS rules (CSRF forms, DOM XSS), project rules (exposed files, .htaccess) and runtime lifecycle checks. - JSON report, new HTML report, console summary, --fail-on, --min-severity/--min-confidence, --second-order, baselines and inline asst-ignore suppressions. Benchmark (bench/RESULTS.md): NIST SARD sample F1 35.6% -> 66.5%, DVWA F1 84.6% -> 88.0% (precision 100%), fixture corpus 100%. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…utput - HTML report: a single self-contained file that works offline, with severity tiles, search, filters (severity, confidence, OWASP 2025 category), grouping by category/file/rule, highlighted code snippets, data-flow traces, dark mode and print layout. All content is escaped and the inline script is allowed only by its SHA-256 hash (CSP). - SARIF 2.1.0 for GitHub code scanning and IDE viewers: CWE and OWASP tags, security-severity, stable partial fingerprints and code flows. Validated against the official schema in the test suite. - Markdown summary for pull requests and CI job summaries. - Baselines: --update-baseline / --baseline mark findings as new or unchanged and list fixed ones in every format. - Clearer messages: plain-language sink contexts and assignment steps in the data-flow trace. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- New Markdown remediation guides (langs/php/guides) with one section per rule: explanation, vulnerable and fixed PHP 8 examples, and OWASP cheat sheet references. The matching section is embedded under each finding in the HTML report and used as SARIF rule help. - The eleven PDF/DOCX guides were revised for current PHP and the OWASP Top 10:2025: PDO prepared-statement settings, per-argument shell escaping, context-aware output encoding, password_hash()-based storage, HTTPS/HSTS configuration, current XML parser defaults, SSRF allow-lists, MongoDB and logging examples, and links to the 2025 categories. PDFs were re-exported from the revised documents. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Includes are resolved and executed in the including scope, as PHP does: __DIR__/__FILE__, dirname(), define()d paths and file names chosen in a switch (several possible values) are followed, with *_once tracking and depth limits. - Functions, classes and methods are resolved across the project; analysis results are shared between entry scripts, and findings in shared helpers list the entry points that reach them. - Structural rules run in a single pass with memoized name lookups; DOM XSS checks focus on real browser sources and skip minified bundles. Benchmark: DVWA F1 96.3% (precision 100%), NIST SARD sample 66.5%, WordPress core (1,512 PHP files) scanned in about 12 seconds. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Automatic framework detection (composer.json/lock, WordPress core,
plugin and theme headers) with packs that extend the taint catalog:
request sources, escaping helpers, query builders, $wpdb, redirects
and HTTP clients.
- Template checks for raw Blade {!! !!} and Twig |raw / autoescape false.
- Mass assignment, framework debug mode (.env, config/app.php,
wp-config.php), CSRF exemptions and WordPress AJAX/admin-post
handlers without nonce and capability checks.
- Framework-aware CSRF token helpers; array_map() callback modelling.
- Guide sections and fixtures for each framework.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Component inventory from composer.lock, package-lock.json (v1-v3) and yarn.lock, plus JavaScript libraries copied into the project, shown in a new Components section of every report. - Bundled advisory data for common front-end libraries; --online checks every package against OSV.dev (names and versions only, cached 24 h). - End-of-life checks for frameworks and libraries, development packages installed in production and abandoned Composer packages. - Secrets detection for provider tokens, private keys, JWTs, connection URLs and secret assignments in code and configuration files, masked in every report format. - Lifecycle data for more products, refreshable with --online or npm run update-data. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- --url (or LIVE_SCAN_URL) checks the running site with read-only GET and HEAD requests: security headers, version banners, cookie attributes, HTTPS redirect, CORS origin reflection, PHP error output, directory listings, and whether files flagged by the static scan can be downloaded (confirmed exposures are raised to critical). - Localhost and private networks only unless --allow-remote; the resolved address is pinned, at most 60 requests at five per second, no cookies sent and no response content copied into reports. - php.ini audit through the PHP binary: error display, expose_php, allow_url_include, session settings and optional hardening. - Guide sections for security headers, php.ini, session cookies and CORS. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- JavaScript and TypeScript scanning (@babel/parser 7.29) on the shared data-flow engine: request data is followed through functions, closures, callbacks, promises and modules into SQL and NoSQL queries, shell commands, eval/vm, dynamic require/import, HTML responses and templates, file paths, outgoing requests, redirects, RegExp construction, deep merges and deserializers. - Configuration checks for helmet/security headers, CORS, session cookies, JWT verification, TLS certificate checks, express.static() on the project folder, password hashing, Math.random() tokens and end-of-life Node.js versions; raw output in EJS, Handlebars, Pug, Nunjucks and Vue templates. - Dependencies, secrets, live checks and reports shared with the PHP plugin through a common plugin kit; --lang nodejs or auto. - Remediation guides for Node.js, an annotated fixture corpus and a sample Express application. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Composite GitHub Action: scans the repository, uploads SARIF to code scanning, writes the Markdown summary and applies a fail-on threshold; actions pinned to commit SHAs, tested in CI. - Docker image on a digest-pinned node:22-alpine base, running as an unprivileged user (scan /src, reports in /out). - ASST_OUT and ASST_NO_DB environment variables. - README and project page: what's new in v2 and a usage reference (CLI, reports, CI, Node.js, live checks, privacy, Docker, suppressions, limitations). The installation sections are unchanged. - CONTRIBUTING.md, SECURITY.md, final changelog, version 2.0.0 and an asst command; refreshed benchmark results. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Badge row: CI, version, license, Node.js 18+, OWASP Top 10:2025, scanned languages, platforms, stars and Buy Me a Coffee. - New README sections: Security, Development, Documentation and License. - THIRD_PARTY_NOTICES.md for npm packages, bundled data and benchmark datasets; included in the npm package files and the Docker image. - ASST is no longer labelled beta. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.