npm / @babel/generator / 8.0.6

@babel/generator 8.0.6

Source
https://github.com/babel/babel
Tag scanned
v8.0.6
Directory
packages/babel-generator (only this part of the repository was scanned)
Compared with
v8.0.5 (0 signals introduced since)
Files
1152 scanned, 148 skipped (binary, oversized, or unrecognised)
Signals
0 critical · 0 warn · 62 info
Scan time
8.0 s
LLM review
Reviewed by claude-haiku-5-5 (Anthropic): 7 of 7 warn and critical signals; 7 demoted to info.
Disclude version
4.1.0
Scanned (UTC)
2026-10-22 14:51

Signals

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

  1. dynamic `import(...)` with a non-literal specifier (ast pass, confidence 0.65)

    /*0*/import/*1*/(/*2*/"foo"/*3*/)/*4*/
    likely benign LLM, confidence 0.93 Comment-laden dynamic import("foo") in a parser test fixture.
    Reasoning

    The snippet is a dynamic import whose specifier is the string literal "foo", with comments between the tokens. It sits in a parser fixture named for comment handling, so the flag comes from the scanner's own test input rather than from a real loader. The literal specifier makes the non-literal message a false positive.

  2. dynamic `import(...)` with a non-literal specifier (ast pass, confidence 0.65)

    /*0*/import /*1*/(/*2*/"foo" /*3*/); /*4*/
    likely benign LLM, confidence 0.93 Formatted expected output of a dynamic import("foo") fixture with comments.
    Reasoning

    This is the formatted output counterpart of the comment-handling fixture. It contains import("foo") with a literal string specifier and interleaved comments, which is expected output for a formatter test. Nothing here is a non-literal specifier or an evasion attempt.

  3. 17 of 42 non-conventional identifiers are single-character (40%) (token pass, confidence 0.50)

  4. 17 of 42 non-conventional identifiers are single-character (40%) (token pass, confidence 0.50)

  5. 15 of 35 non-conventional identifiers are single-character (43%) (token pass, confidence 0.50)

  6. 15 of 35 non-conventional identifiers are single-character (43%) (token pass, confidence 0.50)

  7. line length 2112 characters (mostly string/comment) (raw pass, confidence 0.39)

    "undefined" === typeof Aura && (Aura = {}); Aura.bootstrap || (Aura.bootstrap = {}); Aura.frameworkJsReady || (Aura.ApplicationDefs = { cmpExporter: {}, libExporter: {} }, $A = { componentService: { addComponent: function (a, b) { Aura.ApplicationDefs.cmpExporter[a] = b; }, addLibraryExporter: function (a, b) { Aura.Ap
  8. mean non-conventional identifier length 1.90 over 41 names (token pass, confidence 0.50)

  9. mean non-conventional identifier length 1.90 over 41 names (token pass, confidence 0.50)

  10. 42 of 74 non-conventional identifiers are single-character (57%) (token pass, confidence 0.50)

  11. 42 of 74 non-conventional identifiers are single-character (57%) (token pass, confidence 0.50)

  12. 30 of 54 non-conventional identifiers are single-character (56%) (token pass, confidence 0.50)

  13. 30 of 54 non-conventional identifiers are single-character (56%) (token pass, confidence 0.50)

  14. mean non-conventional identifier length 1.43 over 21 names (token pass, confidence 0.50)

  15. mean non-conventional identifier length 1.43 over 21 names (token pass, confidence 0.50)

  16. mean non-conventional identifier length 1.65 over 20 names (token pass, confidence 0.50)

  17. mean non-conventional identifier length 1.65 over 20 names (token pass, confidence 0.50)

  18. 26 of 46 non-conventional identifiers are single-character (57%) (token pass, confidence 0.50)

  19. 26 of 46 non-conventional identifiers are single-character (57%) (token pass, confidence 0.50)

  20. mean non-conventional identifier length 1.38 over 48 names (token pass, confidence 0.50)

  21. mean non-conventional identifier length 1.38 over 48 names (token pass, confidence 0.50)

  22. dynamic `import(...)` with a non-literal specifier (ast pass, confidence 0.65)

    /* 0 */import/* 1 */./* 2 */source/* 3 */(/* 4 */"foo"/* 5 */, /* 6 */)/* 7 */;
    likely benign LLM, confidence 0.92 Test fixture for source-phase import.source("foo") with comments.
    Reasoning

    This is an import-phases fixture exercising the source-phase syntax import.source(...) with comments in between. The specifier is the literal "foo". The finding is a parser-coverage artifact of the test corpus, not code that runs.

  23. dynamic `import(...)` with a non-literal specifier (ast pass, confidence 0.65)

    /* 0 */import /* 1 */ /* 2 */ /* 3 */.source(/* 4 */"foo" /* 5 */ /* 6 */) /* 7 */;
    likely benign LLM, confidence 0.92 Expected formatted output for an import.source("foo") comment fixture.
    Reasoning

    This is the expected formatted output for the source-phase import comment fixture. It uses the literal specifier "foo" and has no sensitive behavior.

  24. dynamic `import(...)` with a non-literal specifier (ast pass, confidence 0.65)

    /* 0 */import/* 1 */./* 2 */source/* 3 */(/* 4 */"foo"/* 5 */, /* 6 */options/* 7 */,/* 8 */)/* 9 */;
    likely benign LLM, confidence 0.92 Test fixture for import.source("foo", options) with comments.
    Reasoning

    This fixture covers the source-phase import with an options argument and comments. The specifier is the literal "foo", and the options object is a plain identifier in a test input. It is a parser test, not a loader of attacker-controlled modules.

  25. dynamic `import(...)` with a non-literal specifier (ast pass, confidence 0.65)

    /* 0 */import /* 1 */ /* 2 */ /* 3 */.source(/* 4 */"foo" /* 5 */, /* 6 */options /* 7 */ /* 8 */) /* 9 */;
    likely benign LLM, confidence 0.92 Expected formatted output for an import.source("foo", options) comment fixture.
    Reasoning

    This is the formatted expected output of the options-plus-comments source-phase import fixture. It contains only the literal "foo" specifier and an options identifier, with no dynamic or malicious behavior.

  26. orphaned high surrogate \uD83D (no matching low surrogate) (token pass, confidence 0.65)

    "😂";
    "\uD83D_\uDE02"
    `😂`;
    /foobar/g;
  27. orphaned low surrogate \uDE02 (no preceding high surrogate) (token pass, confidence 0.65)

    "😂";
    "\uD83D_\uDE02"
    `😂`;
    /foobar/g;
  28. orphaned high surrogate \uD83D (no matching low surrogate) (token pass, confidence 0.65)

    5;5;50;5e4;"foobar";" ";"\n\r";"😂";"\uD83D_\uDE02"`😂`;/foobar/g;null;true;false;5;2;56;31;
  29. orphaned low surrogate \uDE02 (no preceding high surrogate) (token pass, confidence 0.65)

    5;5;50;5e4;"foobar";" ";"\n\r";"😂";"\uD83D_\uDE02"`😂`;/foobar/g;null;true;false;5;2;56;31;
  30. mean non-conventional identifier length 1.26 over 23 names (token pass, confidence 0.50)

  31. mean non-conventional identifier length 1.26 over 23 names (token pass, confidence 0.50)

  32. mean non-conventional identifier length 1.98 over 299 names (token pass, confidence 0.50)

  33. mean non-conventional identifier length 1.98 over 299 names (token pass, confidence 0.50)

  34. 23 of 50 non-conventional identifiers are single-character (46%) (token pass, confidence 0.50)

  35. 23 of 50 non-conventional identifiers are single-character (46%) (token pass, confidence 0.50)

  36. mean non-conventional identifier length 1.46 over 35 names (token pass, confidence 0.50)

  37. mean non-conventional identifier length 1.46 over 35 names (token pass, confidence 0.50)

  38. 34 of 48 non-conventional identifiers are single-character (71%) (token pass, confidence 0.50)

  39. 34 of 48 non-conventional identifiers are single-character (71%) (token pass, confidence 0.50)

  40. 34 of 48 non-conventional identifiers are single-character (71%) (token pass, confidence 0.50)

  41. 34 of 48 non-conventional identifiers are single-character (71%) (token pass, confidence 0.50)

  42. 30 of 60 non-conventional identifiers are single-character (50%) (token pass, confidence 0.50)

  43. 30 of 60 non-conventional identifiers are single-character (50%) (token pass, confidence 0.50)

  44. 25 of 51 non-conventional identifiers are single-character (49%) (token pass, confidence 0.50)

  45. 25 of 51 non-conventional identifiers are single-character (49%) (token pass, confidence 0.50)

  46. file mixes tab and space indentation (8 tab-indented and 2 space-indented lines) (raw pass, confidence 0.40)

    function assertElement(assertFn, shouldBeElement, opt_message) {
      return /** @type {!Ele	ment} */ (
    	  assertType_(
    	    assertFn,
  47. file mixes tab and space indentation (8 tab-indented and 2 space-indented lines) (raw pass, confidence 0.40)

    function assertElement(assertFn, shouldBeElement, opt_message) {
      return /** @type {!Ele	ment} */ (
    	  assertType_(
    	    assertFn,
  48. file mixes tab and space indentation (8 tab-indented and 2 space-indented lines) (raw pass, confidence 0.40)

    function assertElement(assertFn, shouldBeElement, opt_message) {
      return /** @type {!Ele	ment} */ (
    	  assertType_(
    	    assertFn,
  49. file mixes tab and space indentation (8 tab-indented and 2 space-indented lines) (raw pass, confidence 0.40)

    function assertElement(assertFn, shouldBeElement, opt_message) {
      return /** @type {!Ele	ment} */ (
    	  assertType_(
    	    assertFn,
  50. 25 of 33 non-conventional identifiers are single-character (76%) (token pass, confidence 0.50)

  51. 25 of 33 non-conventional identifiers are single-character (76%) (token pass, confidence 0.50)

  52. mean non-conventional identifier length 1.61 over 90 names (token pass, confidence 0.50)

  53. mean non-conventional identifier length 1.61 over 90 names (token pass, confidence 0.50)

  54. 38 of 56 non-conventional identifiers are single-character (68%) (token pass, confidence 0.50)

  55. 38 of 56 non-conventional identifiers are single-character (68%) (token pass, confidence 0.50)

  56. 38 of 56 non-conventional identifiers are single-character (68%) (token pass, confidence 0.50)

  57. 38 of 56 non-conventional identifiers are single-character (68%) (token pass, confidence 0.50)

  58. 21 of 40 non-conventional identifiers are single-character (52%) (token pass, confidence 0.50)

  59. 21 of 40 non-conventional identifiers are single-character (52%) (token pass, confidence 0.50)

  60. 13 of 30 non-conventional identifiers are single-character (43%) (token pass, confidence 0.50)

  61. 13 of 30 non-conventional identifiers are single-character (43%) (token pass, confidence 0.50)

  62. info critical → info by review dynamic-execution packages/babel-generator/test/index.js:1038:5

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

        );
        new Function(generate(mem).code);
      });
    likely benign LLM, confidence 0.80 Test harness constructing a Function from code generated by the tool's own generator.
    Reasoning

    The file is the scanner's own test suite. The flagged new Function(generate(mem).code) most likely appears in a test harness that evaluates code produced by the tool's own generator, checking that output is valid or behaves correctly. The source is local and generated, not attacker-supplied. Some doubt remains because the pattern is a real dynamic-execution sink, and only the snippet is visible.

Reproduce This Scan

Run disclude locally to verify. 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.1.0
git clone https://github.com/babel/babel babel && cd babel
git checkout v8.0.6
disclude scan --severity info --diff v8.0.5 packages/babel-generator