npm / tapable / 2.3.4

tapable 2.3.4

Source
https://github.com/webpack/tapable
Artifact scanned
tapable-2.3.4.tgz (npm tarball · 22.8 KB · SHA-256 2fcebeb70c5c…)
Compared with
tapable-2.3.3.tgz (0 signals introduced since)
Files
19 scanned, 1 skipped (binary, oversized, or unrecognised)
Signals
0 critical · 0 warn · 3 info
Scan time
3.5 s
LLM review
Reviewed by claude-haiku-5-5 (Anthropic): 3 of 3 warn and critical signals; 3 demoted to info.
Disclude version
4.3.0
Scanned (UTC)
2026-11-15 09:42

Signals

Ordered by severity, then signals introduced in this release. Hidden characters are shown as ⟨U+…⟩.

  1. info critical → info by review dynamic-execution lib/HookCodeFactory.js:90:10

    `Function(...)` called with a non-literal body (ast pass, confidence 0.75)

    			case "sync":
    				fn = new Function(
    					this.args(),
    					`"use strict";\n${this.header()}${this.contentWithInterceptors({
    likely benign LLM, confidence 0.95 Generates the synchronous hook invocation function body via new Function in the tapable library.
    Reasoning

    This is tapable's HookCodeFactory, which builds hook call functions from generated source using the Function constructor. The body is assembled from the hook's own header, interceptor and argument templates, not from untrusted input. This is a known, legitimate code-generation pattern for performance, and the file context supports it.

  2. info critical → info by review dynamic-execution lib/HookCodeFactory.js:102:10

    `Function(...)` called with a non-literal body (ast pass, confidence 0.75)

    			case "async":
    				fn = new Function(
    					this.args({
    						after: "_callback"
    likely benign LLM, confidence 0.95 Generates the asynchronous hook invocation function via new Function in tapable.
    Reasoning

    The same tapable code-generation pattern: the async branch builds a function body from the library's own templates (args with an _callback parameter, header, interceptors). No external or attacker-controlled data reaches the constructed body in the snippet.

  3. info critical → info by review dynamic-execution lib/HookCodeFactory.js:142:10

    `Function(...)` called with a non-literal body (ast pass, confidence 0.75)

    				code += "}));\n";
    				fn = new Function(this.args(), code);
    				break;
    			}
    likely benign LLM, confidence 0.95 Final compilation step of tapable's generated hook function using new Function.
    Reasoning

    The code string is built by appending library-generated fragments in tapable's factory, then passed to new Function. This is the same legitimate code generator; the flagged construction is internal and does not take untrusted input in the shown context.

Reproduce This Scan

Run disclude locally to verify. These commands scan the published file; the "new in this release" marks come from comparing it with the previous release's file, which they don't repeat. Add --format sarif for SARIF output. Add --llm (with an API key in the environment) to include the LLM review.

cargo install disclude --version 4.3.0
curl -fsSL -o tapable-2.3.4.tgz https://registry.npmjs.org/tapable/-/tapable-2.3.4.tgz
printf '%s  %s\n' 2fcebeb70c5cf83c8c368cda2b8cfa12ec38412a1d392741d3997851649c42d2 tapable-2.3.4.tgz | shasum -a 256 -c -
mkdir pkg && tar -xzf tapable-2.3.4.tgz -C pkg --strip-components 1
disclude scan --untrusted --severity info pkg