Python binding for curl-impersonate fork via cffi. A http client that can impersonate browser tls/ja3/http2 fingerprints.
This report summarizes scanner evidence for lexiforest/curl_cffi, a Python project with 6,698 GitHub stars. SynthScan examined 30,151 lines of code across 120 source files, recording 683 pattern matches distributed across 16 syntactic categories. The legacy adjusted pattern signal is 29.2 (Elevated pattern signal); it is not an authorship estimate.
Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.
Use each vector to guide manual verification of the underlying findings.
Can maintainers explain intent, assumptions, and trade-offs? 464 finding(s).
Are imports declared and package/API names verified? 101 finding(s).
Are wrappers, guards, and repeated structures necessary? 512 finding(s).
Which changes need focused human review? 683 finding(s).
This chart tracks the legacy adjusted pattern score across scan runs. Changes can reflect source changes, scan coverage, or detector/scoring versions; they do not measure AI adoption or prove that a team refactored code. Compare runs only when their scoring versions are compatible. The dashed line tracks the raw pattern-hit count.
Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.
This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.
The scanner identified 683 distinct pattern matches across 16 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.
Reading the findings table: The Severity column indicates the configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | benchmark/ws_bench_2_sync.py | 26 | async def server_recv_benchmark_handler(ws: web.WebSocketResponse) -> None: | CODE |
| LOW | benchmark/ws_bench_2_sync.py | 80 | async def server_send_benchmark_handler(ws: web.WebSocketResponse) -> None: | CODE |
| LOW | benchmark/ws_bench_2_sync.py | 162 | def client_recv_benchmark_handler(ws: WebSocket) -> None: | CODE |
| LOW | benchmark/ws_bench_2_sync.py | 211 | def client_send_benchmark_handler(ws: WebSocket) -> None: | CODE |
| LOW | benchmark/ws_bench_utils.py | 144 | def binary_data_generator_sync( | CODE |
| LOW⚡ | tests/unittest/test_async_websockets.py | 1245 | async def test_ping_too_large_raises(self, ws_connection: AsyncWebSocket) -> None: | CODE |
| LOW⚡ | tests/unittest/test_async_websockets.py | 1250 | async def test_ping_default_payload(self, ws_connection: AsyncWebSocket) -> None: | CODE |
| LOW⚡ | tests/unittest/test_async_websockets.py | 1260 | async def test_pong_default_payload(self, ws_connection: AsyncWebSocket) -> None: | CODE |
| LOW⚡ | tests/unittest/test_async_websockets.py | 1270 | async def test_pong_too_large_raises(self, ws_connection: AsyncWebSocket) -> None: | CODE |
| LOW⚡ | tests/unittest/test_async_websockets.py | 1275 | async def test_control_payload_limit_counts_bytes( | CODE |
| LOW⚡ | tests/unittest/test_async_websockets.py | 1406 | async def test_full_session_lifecycle( | CODE |
| LOW⚡ | tests/unittest/test_async_websockets.py | 1468 | async def test_various_recv_queue_sizes( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 166 | async def close_immediately_handler( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 265 | def start_configurable_ws_server( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 543 | async def test_echo_multiple_messages(self, ws_connection: AsyncWebSocket) -> None: | CODE |
| LOW | tests/unittest/test_async_websockets.py | 633 | async def test_pong_is_silently_consumed( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 653 | async def test_server_ping_is_silently_consumed( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 692 | async def test_recv_timeout_returns_if_data_arrives( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 723 | async def test_message_at_curl_frame_boundary( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 732 | async def test_message_just_over_frame_boundary( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 745 | async def test_concurrent_recv_single_consumer( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 761 | async def test_concurrent_recv_multiple_consumers( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 789 | async def test_send_while_receiving(self, ws_connection: AsyncWebSocket) -> None: | CODE |
| LOW | tests/unittest/test_async_websockets.py | 810 | async def test_more_recv_callers_than_queue_size( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 867 | async def test_recv_callers_exceed_queue_with_slow_producer( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 929 | async def test_concurrent_recv_with_connection_close( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 998 | async def test_cancel_recv_before_message( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1053 | async def test_recv_after_close_raises( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1066 | async def test_send_after_close_raises( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1078 | async def test_server_close_received( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1125 | async def test_aiter_on_closed_raises( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1138 | async def test_iterator_skips_control_frames( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1163 | async def test_recv_queue_size_limit( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1193 | async def test_drain_on_error_false( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1291 | async def test_flush_waits_for_queue(self, ws_connection: AsyncWebSocket) -> None: | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1303 | async def test_is_alive_true_when_connected( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1309 | async def test_is_alive_false_after_close( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1323 | async def test_close_code_and_reason( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1361 | async def test_empty_string_message(self, ws_connection: AsyncWebSocket) -> None: | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1382 | async def test_binary_all_byte_values(self, ws_connection: AsyncWebSocket) -> None: | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1490 | async def test_various_send_queue_sizes( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1586 | async def test_various_max_message_sizes( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1606 | async def test_client_enforces_max_message_size( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1636 | async def test_server_enforces_max_message_size( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1670 | async def test_coalesce_frames_enabled( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1699 | async def test_coalesce_frames_disabled( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1716 | async def test_coalesce_send_then_recv( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1735 | async def test_coalesce_preserves_message_order( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1768 | async def test_coalesce_control_frame_interleaving( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1804 | async def test_coalesce_never_merges_control_frames( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1831 | async def test_partial_write_exact_boundary_resumption( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1890 | async def test_send_eagain_retry_preserves_state( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 1925 | async def test_manual_fragmentation_with_cont_flag( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 2010 | async def test_autoclose_false_survives_close_frame( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 2054 | async def test_block_on_recv_queue_full_true( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 2080 | async def test_block_on_recv_queue_full_false( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 2187 | async def test_close_with_long_reason( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 2224 | async def test_send_binary_explicit( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 2238 | async def test_multiple_flush_calls( | CODE |
| LOW | tests/unittest/test_async_websockets.py | 2259 | async def test_close_code_extraction( | CODE |
| 322 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | benchmark/ws_bench_1_client.py | 174 | except CancelledError: | CODE |
| HIGH | tests/unittest/test_async_websockets.py | 108 | except (ConnectionClosedOK, ConnectionClosedError): | CODE |
| HIGH | tests/unittest/test_async_websockets.py | 122 | except (ConnectionClosedOK, ConnectionClosedError): | CODE |
| HIGH | tests/unittest/test_async_websockets.py | 136 | except (ConnectionClosedOK, ConnectionClosedError): | CODE |
| HIGH | tests/unittest/test_async_websockets.py | 162 | except (ConnectionClosedOK, ConnectionClosedError): | CODE |
| HIGH | tests/unittest/test_async_websockets.py | 185 | except (ConnectionClosedOK, ConnectionClosedError): | CODE |
| HIGH | tests/unittest/test_async_websockets.py | 196 | except (ConnectionClosedOK, ConnectionClosedError): | CODE |
| HIGH | tests/unittest/test_async_websockets.py | 207 | except (ConnectionClosedOK, ConnectionClosedError): | CODE |
| HIGH | tests/unittest/conftest.py | 748 | except (ConnectionClosedOK, ConnectionClosedError): | CODE |
| HIGH | tests/unittest/conftest.py | 855 | except TypeError: | CODE |
| HIGH | tests/unittest/conftest.py | 861 | except Exception: | CODE |
| HIGH | tests/unittest/test_sync_websockets.py | 88 | except (ConnectionClosedOK, ConnectionClosedError): | CODE |
| HIGH | tests/unittest/test_sync_websockets.py | 100 | except (ConnectionClosedOK, ConnectionClosedError): | CODE |
| HIGH | tests/unittest/test_sync_websockets.py | 116 | except (ConnectionClosedOK, ConnectionClosedError): | CODE |
| HIGH | tests/unittest/test_sync_websockets.py | 137 | except (ConnectionClosedOK, ConnectionClosedError): | CODE |
| HIGH | tests/unittest/test_sync_websockets.py | 147 | except (ConnectionClosedOK, ConnectionClosedError): | CODE |
| HIGH | tests/unittest/test_sync_websockets.py | 157 | except (ConnectionClosedOK, ConnectionClosedError): | CODE |
| HIGH | examples/websockets/long_running_async.py | 22 | except (KeyboardInterrupt, asyncio.CancelledError): | CODE |
| HIGH | examples/websockets/long_running_sync.py | 20 | except KeyboardInterrupt: | CODE |
| HIGH | curl_cffi/_asyncio_selector.py | 219 | except RuntimeError: | CODE |
| HIGH | curl_cffi/_asyncio_selector.py | 226 | except AttributeError: | CODE |
| HIGH | curl_cffi/cli/output.py | 98 | except (json.JSONDecodeError, ValueError): | CODE |
| HIGH | curl_cffi/requests/streams.py | 117 | except (AttributeError, OSError): | CODE |
| HIGH | curl_cffi/requests/websockets.py | 158 | except InvalidStateError: | CODE |
| HIGH | curl_cffi/requests/websockets.py | 1803 | except QueueEmpty: | CODE |
| HIGH | curl_cffi/requests/websockets.py | 2503 | except CancelledError: | CODE |
| HIGH | curl_cffi/requests/websockets.py | 2631 | except CancelledError: | CODE |
| HIGH | curl_cffi/requests/websockets.py | 1839 | except CancelledError: | CODE |
| HIGH | curl_cffi/requests/websockets.py | 2843 | except CancelledError: | CODE |
| HIGH | curl_cffi/requests/websockets.py | 2382 | except Exception: | CODE |
| HIGH | curl_cffi/requests/websockets.py | 2759 | except Exception: | CODE |
| HIGH | curl_cffi/requests/utils.py | 1046 | except ValueError: | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM⚡ | tests/unittest/test_async_websockets.py | 1398 | # ============================================================================= | COMMENT |
| MEDIUM⚡ | tests/unittest/test_async_websockets.py | 1400 | # ============================================================================= | COMMENT |
| MEDIUM⚡ | tests/unittest/test_async_websockets.py | 1459 | # ============================================================================= | COMMENT |
| MEDIUM⚡ | tests/unittest/test_async_websockets.py | 1461 | # ============================================================================= | COMMENT |
| MEDIUM | tests/unittest/test_async_websockets.py | 60 | # ============================================================================= | COMMENT |
| MEDIUM | tests/unittest/test_async_websockets.py | 62 | # ============================================================================= | COMMENT |
| MEDIUM | tests/unittest/test_async_websockets.py | 334 | # ============================================================================= | COMMENT |
| MEDIUM | tests/unittest/test_async_websockets.py | 336 | # ============================================================================= | COMMENT |
| MEDIUM | tests/unittest/test_async_websockets.py | 464 | # ============================================================================= | COMMENT |
| MEDIUM | tests/unittest/test_async_websockets.py | 466 | # ============================================================================= | COMMENT |
| MEDIUM | tests/unittest/test_async_websockets.py | 505 | # ============================================================================= | COMMENT |
| MEDIUM | tests/unittest/test_async_websockets.py | 507 | # ============================================================================= | COMMENT |
| MEDIUM | tests/unittest/test_async_websockets.py | 2202 | # ============================================================================= | COMMENT |
| MEDIUM | tests/unittest/test_async_websockets.py | 2204 | # ============================================================================= | COMMENT |
| MEDIUM⚡ | tests/unittest/test_curl.py | 459 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/unittest/test_curl.py | 461 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/unittest/test_sync_websockets.py | 260 | # ============================================================================= | COMMENT |
| MEDIUM | tests/unittest/test_sync_websockets.py | 262 | # ============================================================================= | COMMENT |
| MEDIUM | tests/unittest/test_sync_websockets.py | 302 | # ============================================================================= | COMMENT |
| MEDIUM | tests/unittest/test_sync_websockets.py | 304 | # ============================================================================= | COMMENT |
| MEDIUM⚡ | tests/unittest/cli/test_run.py | 145 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/unittest/cli/test_run.py | 147 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/unittest/cli/test_run.py | 18 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/unittest/cli/test_run.py | 20 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/unittest/cli/test_run.py | 230 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/unittest/cli/test_run.py | 232 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | curl_cffi/cli/run.py | 14 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | curl_cffi/cli/run.py | 17 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | curl_cffi/cli/run.py | 165 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | curl_cffi/cli/run.py | 167 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | curl_cffi/cli/run.py | 233 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | curl_cffi/cli/run.py | 235 | # --------------------------------------------------------------------------- | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/unittest/test_async_websockets.py | 17 | CODE | |
| LOW | tests/unittest/test_sync_websockets.py | 18 | CODE | |
| LOW | curl_cffi/curl.py | 1 | CODE | |
| LOW | curl_cffi/__init__.py | 57 | CODE | |
| LOW | curl_cffi/__init__.py | 59 | CODE | |
| LOW | curl_cffi/__init__.py | 59 | CODE | |
| LOW | curl_cffi/__init__.py | 59 | CODE | |
| LOW | curl_cffi/__init__.py | 59 | CODE | |
| LOW | curl_cffi/__init__.py | 62 | CODE | |
| LOW | curl_cffi/__init__.py | 62 | CODE | |
| LOW | curl_cffi/__init__.py | 63 | CODE | |
| LOW | curl_cffi/__init__.py | 64 | CODE | |
| LOW | curl_cffi/__init__.py | 64 | CODE | |
| LOW | curl_cffi/__init__.py | 64 | CODE | |
| LOW | curl_cffi/__init__.py | 64 | CODE | |
| LOW | curl_cffi/__init__.py | 64 | CODE | |
| LOW | curl_cffi/__init__.py | 64 | CODE | |
| LOW | curl_cffi/__init__.py | 64 | CODE | |
| LOW | curl_cffi/__init__.py | 64 | CODE | |
| LOW | curl_cffi/__init__.py | 64 | CODE | |
| LOW | curl_cffi/__init__.py | 64 | CODE | |
| LOW | curl_cffi/__init__.py | 64 | CODE | |
| LOW | curl_cffi/__init__.py | 64 | CODE | |
| LOW | curl_cffi/__init__.py | 78 | CODE | |
| LOW | curl_cffi/__init__.py | 78 | CODE | |
| LOW | curl_cffi/__init__.py | 78 | CODE | |
| LOW | curl_cffi/__init__.py | 78 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 80 | CODE | |
| LOW | curl_cffi/__init__.py | 114 | CODE | |
| LOW | curl_cffi/__init__.py | 114 | CODE | |
| LOW | curl_cffi/__init__.py | 114 | CODE | |
| 41 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | curl_cffi/curl.py | 803 | Send data to a websocket connection. Args: payload: content to send. flags: websocket f | STRING |
| HIGH | curl_cffi/curl.py | 835 | Close a websocket connection. Shorthand for :meth:`ws_send` with close code and message. Note that to completely | STRING |
| HIGH | curl_cffi/requests/websockets.py | 267 | Validate and encode control frame payloads. Args: payload (str | bytes): The control frame payload | STRING |
| HIGH | curl_cffi/requests/websockets.py | 301 | Unpack close frame, decode reason, and validate close status codes. Args: frame (bytes): The WebSoc | STRING |
| HIGH | curl_cffi/requests/websockets.py | 733 | Receive a WebSocket message. This method waits for and returns the next complete WebSocket message. Att | STRING |
| HIGH | curl_cffi/requests/websockets.py | 896 | Receive a text frame. Args: timeout: How many seconds to wait before raising a timeout. Ra | STRING |
| HIGH | curl_cffi/requests/websockets.py | 934 | Receive a JSON frame. Args: loads: JSON decoder. Defaults to :meth:`json.loads`. timeou | STRING |
| HIGH | curl_cffi/requests/websockets.py | 982 | Send a WebSocket message. Args: payload: Data to send (``str``/``bytes``/``bytearray``/``m | STRING |
| HIGH | curl_cffi/requests/websockets.py | 1203 | Send a ping frame. Args: payload (str | bytes, optional): Ping frame payload. Defaults to ``b""``. | STRING |
| HIGH | curl_cffi/requests/websockets.py | 1220 | Send an unsolicited pong frame. Replies to server pings are automatic. Args: payload (str | bytes, | STRING |
| HIGH | curl_cffi/requests/websockets.py | 1759 | Receive a WebSocket message. This method waits for and returns the next complete WebSocket message. Ar | STRING |
| HIGH | curl_cffi/requests/websockets.py | 1874 | Receive a text frame. Args: timeout: How many seconds to wait before raising a timeout. Ra | STRING |
| HIGH | curl_cffi/requests/websockets.py | 1915 | Receive a JSON frame. Args: loads: JSON decoder. Defaults to :meth:`json.loads`. timeou | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | benchmark/ws_bench_2_sync.py | 76 | except Exception: | CODE |
| LOW | benchmark/ws_bench_2_sync.py | 207 | except Exception: | CODE |
| LOW | benchmark/ws_bench_2_sync.py | 228 | except Exception: | CODE |
| LOW | benchmark/benchmark.py | 84 | except Exception: | CODE |
| LOW | benchmark/ws_bench_2.py | 89 | except Exception: | CODE |
| LOW | benchmark/ws_bench_utils.py | 276 | except Exception: | CODE |
| LOW | benchmark/ws_bench_1_client.py | 152 | except Exception: | CODE |
| LOW | benchmark/ws_bench_1_client_sync.py | 138 | except Exception: | CODE |
| LOW | benchmark/ws_bench_1_server.py | 75 | except Exception: | CODE |
| LOW | tests/unittest/conftest.py | 861 | except Exception: | CODE |
| LOW | tests/unittest/test_share.py | 148 | except Exception as e: # noqa: BLE001 | CODE |
| MEDIUM | tests/unittest/test_share.py | 144 | def worker() -> None: | CODE |
| LOW | tests/pro/test_fp_verify.py | 114 | except Exception as exc: | CODE |
| LOW | curl_cffi/aio.py | 291 | except Exception: | CODE |
| MEDIUM | curl_cffi/cli/run.py | 141 | print("Error: no requests found in file.", file=sys.stderr) | CODE |
| MEDIUM | curl_cffi/cli/run.py | 188 | print(f"Error: invalid HAR JSON: {exc}", file=sys.stderr) | CODE |
| MEDIUM | curl_cffi/cli/run.py | 193 | print("Error: no entries found in HAR file.", file=sys.stderr) | CODE |
| MEDIUM⚡ | curl_cffi/cli/run.py | 245 | print(f"Error: file not found: {filepath}", file=sys.stderr) | CODE |
| MEDIUM | curl_cffi/cli/run.py | 257 | print(f"Error: unsupported file format: {filepath}", file=sys.stderr) | CODE |
| LOW | curl_cffi/cli/request.py | 53 | except Exception as e: | CODE |
| MEDIUM | curl_cffi/cli/request.py | 54 | print(f"Error: {e}", file=sys.stderr) | CODE |
| MEDIUM | curl_cffi/cli/parse.py | 57 | print(f"Error: invalid JSON in '{item}': {exc}", file=sys.stderr) | CODE |
| MEDIUM | curl_cffi/cli/parse.py | 75 | print(f"Error: unknown request item '{item}'", file=sys.stderr) | CODE |
| LOW | curl_cffi/cli/doctor.py | 33 | except Exception as exc: | CODE |
| MEDIUM | curl_cffi/requests/websockets.py | 488 | def __next__(self) -> bytes: | CODE |
| LOW | curl_cffi/requests/websockets.py | 331 | except Exception as e: | CODE |
| LOW | curl_cffi/requests/websockets.py | 536 | except Exception as e: | CODE |
| LOW | curl_cffi/requests/websockets.py | 545 | except Exception as exc: | CODE |
| LOW | curl_cffi/requests/websockets.py | 1942 | except Exception as e: | CODE |
| LOW | curl_cffi/requests/websockets.py | 2273 | except Exception: | CODE |
| LOW | curl_cffi/requests/websockets.py | 2368 | except Exception as exc: | CODE |
| LOW | curl_cffi/requests/websockets.py | 2382 | except Exception: | CODE |
| LOW | curl_cffi/requests/websockets.py | 2509 | except Exception as e: | CODE |
| LOW | curl_cffi/requests/websockets.py | 2635 | except Exception as e: | CODE |
| LOW | curl_cffi/requests/websockets.py | 2744 | except Exception as exc: | CODE |
| LOW | curl_cffi/requests/websockets.py | 2759 | except Exception: | CODE |
| LOW | curl_cffi/requests/websockets.py | 2845 | except Exception as exc: | CODE |
| LOW | curl_cffi/requests/session.py | 419 | except Exception: | CODE |
| LOW | curl_cffi/requests/cache.py | 80 | except Exception: | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | benchmark/ws_bench_2.py | 26 | CODE | |
| LOW | benchmark/ws_bench_2.py | 177 | CODE | |
| LOW | tests/unittest/test_async_websockets.py | 2459 | CODE | |
| LOW | tests/unittest/conftest.py | 84 | CODE | |
| LOW | tests/unittest/test_requests.py | 1183 | CODE | |
| LOW | tests/unittest/test_requests.py | 1228 | CODE | |
| LOW | tests/pro/test_fp_verify.py | 57 | CODE | |
| LOW | examples/websockets/simple_sub_sync.py | 8 | CODE | |
| LOW | examples/websockets/long_running_sync.py | 5 | CODE | |
| LOW | examples/websockets/simple_hft_sync.py | 8 | CODE | |
| LOW | curl_cffi/_asyncio_selector.py | 168 | CODE | |
| LOW | curl_cffi/curl.py | 386 | CODE | |
| LOW | curl_cffi/aio.py | 260 | CODE | |
| LOW | curl_cffi/fingerprints.py | 535 | CODE | |
| LOW | curl_cffi/cli/run.py | 56 | CODE | |
| LOW | curl_cffi/cli/parse.py | 45 | CODE | |
| LOW | curl_cffi/cli/output.py | 205 | CODE | |
| LOW | curl_cffi/requests/cookies.py | 137 | CODE | |
| LOW | curl_cffi/requests/impersonate.py | 105 | CODE | |
| LOW | curl_cffi/requests/streams.py | 208 | CODE | |
| LOW | curl_cffi/requests/models.py | 182 | CODE | |
| LOW | curl_cffi/requests/websockets.py | 516 | CODE | |
| LOW | curl_cffi/requests/websockets.py | 732 | CODE | |
| LOW | curl_cffi/requests/websockets.py | 975 | CODE | |
| LOW | curl_cffi/requests/websockets.py | 1241 | CODE | |
| LOW | curl_cffi/requests/websockets.py | 2285 | CODE | |
| LOW | curl_cffi/requests/websockets.py | 2517 | CODE | |
| LOW | curl_cffi/requests/websockets.py | 2642 | CODE | |
| LOW | curl_cffi/requests/session.py | 862 | CODE | |
| LOW | curl_cffi/requests/session.py | 1322 | CODE | |
| LOW | curl_cffi/requests/utils.py | 70 | CODE | |
| LOW | curl_cffi/requests/utils.py | 595 | CODE | |
| LOW | curl_cffi/requests/headers.py | 84 | CODE | |
| LOW | curl_cffi/requests/headers.py | 126 | CODE | |
| LOW | scripts/build.py | 30 | CODE | |
| LOW | scripts/check_preset.py | 27 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | benchmark/ws_bench_utils.py | 109 | # Initialize config object | COMMENT |
| MEDIUM | tests/unittest/test_async_websockets.py | 3103 | # Create a view starting at an odd offset (e.g., address ends in 1, 3, 7) | COMMENT |
| MEDIUM | curl_cffi/_asyncio_selector.py | 125 | # Create a thread to run the select system call. We manage this thread | COMMENT |
| MEDIUM | curl_cffi/_asyncio_selector.py | 299 | # This class is a __getattribute__-based proxy. All attributes other than those | COMMENT |
| MEDIUM | curl_cffi/const.py | 1 | # This file is automatically generated, do not modify it directly. | COMMENT |
| MEDIUM | curl_cffi/requests/websockets.py | 2819 | # Create a task for the queue join operation | COMMENT |
| MEDIUM | scripts/generate_consts.py | 20 | f.write("# This file is automatically generated, do not modify it directly.\n\n") | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/unittest/test_async_websockets.py | 285 | def set_config(cfg: ServerConfig) -> None: | CODE |
| LOW | tests/unittest/test_sync_websockets.py | 211 | def set_config(cfg: ServerConfig) -> None: | CODE |
| LOW | curl_cffi/curl.py | 331 | def _set_error_buffer(self) -> None: | CODE |
| LOW | curl_cffi/curl.py | 892 | def _setopt(self, option: CurlShareOpt, value: Any) -> None: | CODE |
| LOW | curl_cffi/__init__.py | 1 | __all__ = [ | CODE |
| LOW | curl_cffi/aio.py | 13 | __all__ = ["AsyncCurl"] | CODE |
| LOW | curl_cffi/fingerprints.py | 14 | __all__ = [ | CODE |
| LOW | curl_cffi/fingerprints.py | 485 | def set_api_key(cls, api_key: str) -> None: | CODE |
| LOW | curl_cffi/cli/__init__.py | 16 | __all__ = [ | CODE |
| LOW | curl_cffi/requests/cookies.py | 5 | __all__ = ["Cookies"] | CODE |
| LOW | curl_cffi/requests/cookies.py | 222 | def update_cookies_from_curl_changes(self, changes: list[bytes]) -> None: | CODE |
| LOW | curl_cffi/requests/cache.py | 22 | __all__ = [ | CODE |
| LOW | curl_cffi/requests/__init__.py | 1 | __all__ = [ | CODE |
| LOW | curl_cffi/requests/utils.py | 3 | __all__ = ["HttpVersionLiteral", "set_curl_options", "NOT_SET"] | CODE |
| LOW | curl_cffi/requests/errors.py | 3 | __all__ = ["CurlError", "RequestsError", "CookieConflict", "SessionClosed"] | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | curl_cffi/cli/request.py | 16 | CODE | |
| LOW | curl_cffi/requests/websockets.py | 404 | CODE | |
| LOW | curl_cffi/requests/websockets.py | 576 | CODE | |
| LOW | curl_cffi/requests/websockets.py | 1523 | CODE | |
| LOW | curl_cffi/requests/session.py | 226 | CODE | |
| LOW | curl_cffi/requests/session.py | 651 | CODE | |
| LOW | curl_cffi/requests/session.py | 862 | CODE | |
| LOW | curl_cffi/requests/session.py | 1051 | CODE | |
| LOW | curl_cffi/requests/session.py | 1412 | CODE | |
| LOW | curl_cffi/requests/session.py | 1673 | CODE | |
| LOW | curl_cffi/requests/session.py | 1853 | CODE | |
| LOW | curl_cffi/requests/utils.py | 595 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | benchmark/server.py | 21 | # gunicorn benchmark.server:app -b 127.0.0.1:8000 -n benchmark -w 8 -k \ | COMMENT |
| LOW | tests/pro/test_fp_verify.py | 381 | mismatches, | COMMENT |
| LOW | tests/pro/test_fp_verify.py | 401 | # f"{CAPTURED_LABEL} path: {peet_header_path}", | COMMENT |
| LOW | ffi/shim.h | 1 | #include <stdlib.h> | COMMENT |
| LOW | curl_cffi/_asyncio_selector.py | 181 | # this class is only intended for use on windows, where | COMMENT |
| LOW | curl_cffi/requests/impersonate.py | 341 | # 6683-10793:"Unassigned | COMMENT |
| LOW | curl_cffi/requests/impersonate.py | 361 | # 47803-51913:"Unassigned | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | tests/unittest/test_impersonate.py | 58 | # TODO: implement local ja3/akamai verification server with th1. | COMMENT |
| LOW | curl_cffi/cli/run.py | 107 | # TODO: implement body checking | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | examples/upload.py | 23 | # you can add multiple files under the same field name | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | curl_cffi/aio.py | 260 | def process_data(self, sockfd: int, ev_bitmask: int): | CODE |
| LOW | curl_cffi/cli/request.py | 80 | def handle_request( | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | benchmark/ws_bench_utils.py | 237 | # Write file to disk | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | curl_cffi/_asyncio_selector.py | 204 | # polling the waker alone. If we are, just return to the | COMMENT |