PyPI / websockets / 17.2
websockets 17.2
- Source
- https://github.com/python-websockets/websockets
- Tag scanned
17.2- Compared with
17.1(0 signals introduced since)- Files
- 284 scanned, 67 skipped (binary, oversized, or unrecognised)
- Signals
- 1 critical · 0 warn · 43 info
- Scan time
- 25.8 s
- LLM review
- Reviewed by claude-haiku-5-5 (Anthropic): 35 of 35 warn and critical signals; 34 demoted to info.
- Disclude version
- 4.0.0
- Scanned (UTC)
- 2026-10-14 18:19
Signals
Ordered by severity, then signals introduced in this release. Hidden characters are shown as ⟨U+…⟩.
-
= =likely benign Builds a shell command from a template with a sha value and runs it with shell=True.Reasoning
The shell command is a constant template with a commit sha substituted in. The sha comes from git/API data, so this is a shell-injection risk in principle, but the snippet shows no attacker-controlled input path and the file is a compression experiment.
-
⟨U+00A0⟩ ⟨U+00A0⟩ ⟨U+00A0⟩likely benign Git output sample in Heroku deployment docs with a non-breaking space in its indentation.Reasoning
Non-breaking space in the indentation of a terminal transcript (git commit output) is a typical artifact of copying text from a web page or terminal. Nothing in the snippet executes or hides code, and the rst file is documentation.
-
⟨U+00A0⟩ ⟨U+00A0⟩ ⟨U+00A0⟩ ⟨U+00A0⟩likely benign Git output sample in Heroku deployment docs with a non-breaking space in its indentation.Reasoning
Same pattern as the neighbouring finding: plain git output in a documentation code block, with a copy-paste whitespace artifact. Raw-pass findings like this have a high false-positive rate.
-
⟨U+00A0⟩ ⟨U+00A0⟩ ⟨U+00A0⟩likely benign Git output sample in Heroku deployment docs with a non-breaking space in its indentation.Reasoning
Plain git output in a documentation code block. The U+00A0 is a whitespace artifact with no functional effect.
-
⟨U+00A0⟩ ⟨U+00A0⟩likely benign Git output sample in Heroku deployment docs with a non-breaking space in its indentation.Reasoning
Plain git output in a documentation code block. The non-breaking space is a copy-paste artifact in prose-like text.
-
⟨U+00A0⟩likely benign Git push output sample in Heroku docs with a non-breaking space in its indentation.Reasoning
Git push output in a documentation code block with a non-breaking space in the indentation. This is a copy-paste artifact and has no executable effect.
-
⟨U+00A0⟩ ⟨U+00A0⟩ ⟨U+00A0⟩likely benign Git output sample in Koyeb deployment docs with a non-breaking space in its indentation.Reasoning
Git output sample in a Koyeb deployment doc with a non-breaking space in its indentation. This is a documentation copy-paste artifact.
-
⟨U+00A0⟩ ⟨U+00A0⟩ ⟨U+00A0⟩ ⟨U+00A0⟩likely benign Git output sample in Koyeb deployment docs with a non-breaking space in its indentation.Reasoning
Plain git output in a documentation code block. The non-breaking space is a whitespace artifact with no executable content.
-
⟨U+00A0⟩ ⟨U+00A0⟩ ⟨U+00A0⟩likely benign Git output sample in Koyeb deployment docs with a non-breaking space in its indentation.Reasoning
Plain git output in a documentation code block with a copy-paste whitespace artifact.
-
⟨U+00A0⟩ ⟨U+00A0⟩likely benign Git output sample in Koyeb deployment docs with a non-breaking space in its indentation.Reasoning
Plain git output in a documentation code block with a copy-paste whitespace artifact.
-
dismissed Documentation placeholder `<id>` in a websockets URL was misparsed as a shell redirect to a file named id.
Reasoning
The flagged 'redirect' is the shell-style placeholder `<id>` inside a URL in a sample command (`$ websockets wss://<app>-<user>-<id>.koyeb.app/`). It is a documentation placeholder, not a file redirect. The scanner misread the angle brackets as input redirection from a file named `id`. No file is written and nothing is shadowed.
-
dismissed Documentation placeholder `<id>` in a websockets URL was misparsed as a shell redirect to a file named id.
Reasoning
Same false positive: `<id>` is a placeholder in a URL in a documented example command, and the AST pass read it as a redirect. No command shadowing occurs.
-
dismissed Documentation placeholder `<id>` in a websockets URL was misparsed as a shell redirect to a file named id.
Reasoning
Same false positive: the `<id>` URL placeholder in a documented example is parsed as a redirect. Nothing is written to a path that matches a system command.
-
dismissed Documentation placeholder `<id>` in a websockets URL was misparsed as a shell redirect to a file named id.
Reasoning
The `<id>` in the URL is a template placeholder in a documented example command. The AST pass treated the angle brackets as a shell redirect to a file named id, which is a parser misreading of documentation text.
-
=likely benign Runs a fixed git rev-parse command through the shell in an experiment script.Reasoning
The command is a fixed literal git invocation with shell=True. This is unnecessary shell use in an experiment script, not obfuscation or malicious intent.
-
# PyPI disables the "raw" directive. Remove this section of the README.likely benign Module-level exec of the package's own version.py during setup.Reasoning
This is a known websockets packaging idiom that execs the repository's own version.py to read __version__ without importing the package. The file path is fixed and in-repo, so the exec is legitimate.
-
dismissed Calls os.system with an empty string on Windows to enable terminal color handling.
Reasoning
os.system("") on Windows is a well-known trick to enable ANSI escape processing in the console. It runs no real command.
-
info
warn→ info by reviewdecoder-decompress-payloadsrc/websockets/extensions/permessage_deflate.py:72:28=dismissed Creates a zlib decompressor for permessage-deflate WebSocket compression.Reasoning
zlib.decompressobj is the standard RFC 7692 permessage-deflate implementation for WebSocket frames. Decompressing received payloads is the library's core purpose, not a hidden embedded payload.
-
assert < , = returnlikely benign Dynamic __import__ used to resolve a relative module path for a named attribute.Reasoning
This is a compatibility helper that resolves a relative import by name with __import__, a standard pattern for lazy or relative module loading. The source is a module path, not untrusted data.
-
= await == :likely benign Test server evaluates client-sent expressions with eval to return values.Reasoning
This is a test fixture that evals expressions received over the websocket. That is dangerous if deployed, but it is in tests and reflects a deliberate test harness design rather than hidden malware.
-
await = awaitlikely benign Test evaluates a latency value received from the server.Reasoning
The eval parses a latency value the test server returns as a string. It is test-only code with no evidence of malicious intent.
-
await =likely benign Test evaluates a server-returned latency string.Reasoning
Same test pattern as the neighboring finding: eval of a server-reported latency number inside a unit test.
-
await =likely benign Test evaluates a server-returned latency string.Reasoning
Same test pattern: eval of a server-reported latency value in a test case.
-
# Control frames aren't encoded or decoded.dismissed Round-trip repr test that evals the repr of a local extension object.Reasoning
eval(repr(extension)) is a round-trip repr test on a local object the test itself constructs. No external input is involved.
-
=likely benign Legacy test evaluates a close_timeout value received from the server.Reasoning
The eval parses a close_timeout value returned by the test's own server, in a legacy test. It is test-only code with no sign of malicious intent.
-
=likely benign eval of a value received from the test client's websocket inside a legacy client/server test.Reasoning
The eval argument comes from the test's own client over a local test websocket connection, and the result is checked with assertEqual. This is a test fixture evaluating its own controlled values, not an attack.
-
=likely benign eval of a received close-timeout value in a legacy websocket test.Reasoning
Same pattern as the sibling finding: eval of a locally received test value compared against an expected number in a test assertion.
-
= == :likely benign Test server that evals expressions received from its test client over websocket.Reasoning
This is a test server that evals each message received over a websocket. That is poor practice on a network-facing socket, but it is a localhost test fixture whose clients are the library's own tests sending expressions such as ws.latency. The raw eval is not a supply-chain or obfuscation indicator.
-
=likely benign eval of a latency response from the test server in a sync websocket test.Reasoning
The test sends the fixed string 'ws.latency' and evals the reply, which is a numeric latency asserted in the test. Expected test-harness behaviour.
-
=likely benign eval of a latency reply in a sync websocket test.Reasoning
Same as the sibling sync test: eval of a controlled latency reply followed by a positive-value assertion.
-
=likely benign eval of a latency reply in a sync websocket test.Reasoning
Same pattern again: eval of the test server's latency reply, asserted to be zero in a test.
-
, , , , -
, , , ] -
, , , ] -
, , ] ] -
, , ] ] -
= -
= -
-
, , ] -
= await == :likely benign Async trio test server that evals expressions sent by its test client.Reasoning
Async counterpart of the sync test server: it evals messages from the test client over a local websocket. Poor practice in a network-facing context, but confined to a test fixture with no obfuscation or malicious indicators.
-
await = awaitlikely benign eval of a latency reply in a trio websocket test.Reasoning
The test sends 'ws.latency' and evals the reply, which is asserted numerically. Standard test-harness code.
-
await =likely benign eval of a latency reply in a trio websocket test.Reasoning
Same as the sibling trio test: eval of a controlled latency value followed by a positive assertion.
-
await =likely benign eval of a latency reply in a trio websocket test.Reasoning
Same pattern: eval of the test server's latency reply, asserted to be zero.
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.
&&