PyPI / virtualenv / 21.14.12

virtualenv 21.14.12

Source
https://github.com/pypa/virtualenv
Tag scanned
21.14.12
Compared with
21.14.11 (0 signals introduced since)
Files
208 scanned, 33 skipped (binary, oversized, or unrecognised)
Signals
0 critical · 0 warn · 14 info
Scan time
10.4 s
LLM review
Reviewed by claude-haiku-5-5 (Anthropic): 10 of 10 warn and critical signals; 10 demoted to info.
Disclude version
4.0.0
Scanned (UTC)
2026-10-21 07:25

Signals

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

  1. info critical → info by review dynamic-import docs/render_cli.py:40:34

    `__import__` called on a non-literal expression (ast pass, confidence 0.70)

            module_name, attr_name = self.options["module"], self.options["func"]
            parser_creator = getattr(__import__(module_name, fromlist=[attr_name]), attr_name)
            core_result = parse_parser(parser_creator())
    likely benign LLM, confidence 0.80 Sphinx-style docs extension that dynamically imports a parser factory named in its options.
    Reasoning

    The module and attribute names come from the Sphinx directive's configured options, and the code imports a parser factory to render CLI docs. That is a documentation tool loading the module the docs author named, not hidden or attacker-controlled code. The dynamic import is expected here, though the module name is not validated.

  2. info critical → info by review dynamic-import docs/render_cli.py:236:20

    `__import__` called on a non-literal expression (ast pass, confidence 0.70)

        of_class = of_type.split(".")
        data = getattr(__import__(".".join(of_class[:-1]), fromlist=[of_class[-1]]), of_class[-1])
        return [n.literal("", text=",".join(data))], []
    likely benign LLM, confidence 0.80 Docs helper that resolves a class by dotted name from directive input to render its text.
    Reasoning

    The import path is split from a type string taken from the documentation directive's own input, and the result is used only to render text. This is the same documentation-tooling pattern as the other finding in this file, with no network, shell, or encoded payload involved.

  3. info warn → info by review dynamic-execution docs/tutorial/getting-started.rst:102:21

    [embedded bash] command name is a variable (`$which`) not set in this file — the caller or environment decides what runs (ast pass, confidence 0.70)

            (myproject) $ which python
            /home/user/myproject/bin/python
    likely benign LLM, confidence 0.90 Tutorial example output showing `which python` in a virtualenv session.
    Reasoning

    This is an illustrative shell transcript inside an RST tutorial, where `$which` is a placeholder in a prompt example. It does not execute anything in the repository and is not a real dropper or hijack.

  4. info critical → info by review path-command-shadow docs/tutorial/getting-started.rst:109:23

    [embedded bash] redirect writes to `python` — filename matches a system command (PATH hijack setup) (ast pass, confidence 0.88)

            (myproject) PS> where.exe python
            C:\Users\user\myproject\Scripts\python.exe
    dismissed LLM, confidence 0.85 Windows tutorial showing where.exe output for the venv python interpreter.
    Reasoning

    The flagged 'redirect to python' is the scanner misreading a Windows `where.exe python` example and its printed path. The snippet only displays the location of the venv interpreter, so it contains no redirect or PATH manipulation.

  5. info warn → info by review obfuscated-command-name docs/tutorial/getting-started.rst:110:9

    [embedded bash] command name contains 5 backslash-escape sequences — hiding the true command (ast pass, confidence 0.85)

            (myproject) PS> where.exe python
            C:\Users\user\myproject\Scripts\python.exe
    dismissed LLM, confidence 0.90 Windows path in a tutorial transcript flagged for backslash escapes.
    Reasoning

    The backslash count comes from ordinary Windows path separators in `C:\Users\...\Scripts\python.exe` in a documentation example. No command name is obfuscated.

  6. info warn → info by review obfuscated-command-name docs/tutorial/getting-started.rst:117:9

    [embedded bash] command name contains 5 backslash-escape sequences — hiding the true command (ast pass, confidence 0.85)

            (myproject) C:\> where.exe python
            C:\Users\user\myproject\Scripts\python.exe
    dismissed LLM, confidence 0.90 Windows where.exe example in documentation flagged for path backslashes.
    Reasoning

    Same as the adjacent finding: the backslashes are ordinary Windows path separators in a `where.exe python` example. The snippet is a documentation transcript.

  7. info warn → info by review dynamic-execution docs/tutorial/getting-started.rst:127:17

    [embedded bash] command name is a variable (`$pip`) not set in this file — the caller or environment decides what runs (ast pass, confidence 0.70)

        (myproject) $ pip install requests
        Collecting requests
          Using cached requests-2.32.3-py3-none-any.whl (64 kB)
    likely benign LLM, confidence 0.90 Tutorial example showing a pip install session.
    Reasoning

    This is a documentation transcript for `pip install requests` with the prompt shown as `$pip`. It is a placeholder in a tutorial example, not an executed payload.

  8. info warn → info by review dynamic-execution docs/tutorial/getting-started.rst:137:17

    [embedded bash] command name is a variable (`$python`) not set in this file — the caller or environment decides what runs (ast pass, confidence 0.70)

        (myproject) $ python -c "import requests; print(requests.__file__)"
        /home/user/myproject/lib/python3.13/site-packages/requests/__init__.py
    likely benign LLM, confidence 0.90 Tutorial example showing python importing requests to print its path.
    Reasoning

    This is an illustrative example of running python to print the requests package location in a venv. It is standard documentation with no hidden or downloaded command.

  9. info warn → info by review obfuscated-command-name docs/tutorial/getting-started.rst:176:9

    [embedded bash] command name contains 3 backslash-escape sequences — hiding the true command (ast pass, confidence 0.85)

            PS> .\myproject\Scripts\python.exe -c "import sys; print(sys.prefix)"
            C:\Users\user\myproject
    
            PS> .\myproject\Scripts\pip.exe install httpx
    dismissed LLM, confidence 0.90 Windows relative-path example for running the venv python in the tutorial.
    Reasoning

    The three backslashes are the relative Windows path `.\myproject\Scripts\python.exe` in a tutorial example. That is ordinary path syntax, not command-name hiding.

  10. info warn → info by review obfuscated-command-name docs/tutorial/getting-started.rst:185:9

    [embedded bash] command name contains 3 backslash-escape sequences — hiding the true command (ast pass, confidence 0.85)

            C:\> .\myproject\Scripts\python.exe -c "import sys; print(sys.prefix)"
            C:\Users\user\myproject
    
            C:\> .\myproject\Scripts\pip.exe install httpx
    dismissed LLM, confidence 0.90 Windows tutorial example invoking venv python and pip by relative path.
    Reasoning

    This is the same relative Windows path style in a tutorial example, invoking the venv python and pip. The backslashes are path separators, so the flag is a false positive.

  11. info unicode-homoglyph tests/conftest.py:310:47

    identifier `èрт` contains homoglyph candidates: р (0440)→p (in string/comment) (raw pass, confidence 0.35)

        # in PowerShell paths
        base = "'\";&&e-$ !%`|>__VIRTUAL_NAME__[1]èрт🚒♞中片-j"
        if IS_WIN:
            # NTFS path components cannot contain any of these, regardless of where they sit in the string
  12. info unicode-mixed-script tests/conftest.py:310:47

    identifier `èрт` mixes scripts: Latin + Cyrillic (in string/comment) (raw pass, confidence 0.40)

        # in PowerShell paths
        base = "'\";&&e-$ !%`|>__VIRTUAL_NAME__[1]èрт🚒♞中片-j"
        if IS_WIN:
            # NTFS path components cannot contain any of these, regardless of where they sit in the string
  13. identifier `èрт` contains homoglyph candidates: р (0440)→p (in string/comment) (raw pass, confidence 0.35)

        """Exclude ampersands, which batch activation does not support in paths."""
        base = "'\";e-$ èрт🚒♞中片-j"
        if IS_WIN:
            base = base.replace('"', "").replace(";", "")
  14. info unicode-mixed-script tests/unit/activation/test_batch.py:27:21

    identifier `èрт` mixes scripts: Latin + Cyrillic (in string/comment) (raw pass, confidence 0.40)

        """Exclude ampersands, which batch activation does not support in paths."""
        base = "'\";e-$ èрт🚒♞中片-j"
        if IS_WIN:
            base = base.replace('"', "").replace(";", "")

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.0.0
git clone https://github.com/pypa/virtualenv virtualenv && cd virtualenv
git checkout 21.14.12
disclude scan --severity info --diff 21.14.11 .