Goal Reached Thanks to every supporter — we hit 100%!

Goal: 1000 CNY · Raised: 1336 CNY

100%

CWE-670 (控制流实现总是不正确) — Vulnerability Class 79

79 vulnerabilities classified as CWE-670 (控制流实现总是不正确). AI Chinese analysis included.

CWE-670 represents a critical implementation flaw where the actual control flow diverges from the intended algorithmic logic, resulting in consistent incorrect behavior whenever the erroneous path is executed. This weakness typically arises from misunderstandings of language syntax, such as omitting braces in conditional statements or misusing loop structures, causing unintended execution sequences. Attackers exploit these logical gaps to bypass security checks, manipulate data integrity, or trigger denial-of-service conditions by forcing the application down an unexpected code path. To prevent CWE-670, developers must rigorously adhere to coding standards, utilize static analysis tools to detect structural anomalies, and employ comprehensive unit testing that specifically targets edge cases and complex branching logic. Clear code formatting and peer reviews further ensure that the implemented flow accurately mirrors the designed algorithm, eliminating ambiguity and ensuring predictable system behavior.

MITRE CWE Description
The code contains a control flow path that does not reflect the algorithm that the path is intended to implement, leading to incorrect behavior any time this path is navigated. This weakness captures cases in which a particular code segment is always incorrect with respect to the algorithm that it is implementing. For example, if a C programmer intends to include multiple statements in a single block but does not include the enclosing braces (CWE-483), then the logic is always incorrect. This issue is in contrast to most weaknesses in which the code usually behaves correctly, except when it is externally manipulated in malicious ways.
Common Consequences (1)
OtherOther, Alter Execution Logic
Examples (2)
This code queries a server and displays its status when a request comes from an authorized IP address.
$requestingIP = $_SERVER['REMOTE_ADDR']; if(!in_array($requestingIP,$ipAllowList)){ echo "You are not authorized to view this page"; http_redirect($errorPageURL); } $status = getServerStatus(); echo $status; ...
Bad · PHP
In this example, the programmer has indented the statements to call Do_X() and Do_Y(), as if the intention is that these functions are only called when the condition is true. However, because there are no braces to signify the block, Do_Y() will always be executed, even if the condition is false.
if (condition==true) Do_X(); Do_Y();
Bad · C
CVE IDTitleCVSSSeverityPublished
CVE-2025-49091 KDE Konsole 安全漏洞 — Konsole 8.2 High2025-06-11
CVE-2025-32996 http-proxy-middleware 安全漏洞 — http-proxy-middleware 4.0 Medium2025-04-15
CVE-2025-2886 Terminating targets role delegations are not respected in tough — tough 4.3AIMediumAI2025-03-27
CVE-2025-24800 Critical vulnerability in `ismp-grandpa` <v15.0.1 — hyperbridge 7.5 -2025-01-28
CVE-2025-21607 Success of Certain Precompile Calls not Checked in Vyper — vyper 7.1 -2025-01-14
CVE-2024-53271 HTTP/1.1 multiple issues with envoy.reloadable_features.http1_balsa_delay_reset in envoy — envoy 7.1 High2024-12-18
CVE-2024-53270 HTTP/1: sending overload crashes when the request is reset beforehand in envoy — envoy 7.5 High2024-12-18
CVE-2024-53269 Happy Eyeballs: Validate that additional_address are IP addresses instead of crashing when sorting in envoy — envoy 4.5 Medium2024-12-18
CVE-2024-52811 Acks not validated before logged to qlog leads to buffer overflow in ngtcp2 — ngtcp2 8.2 High2024-11-25
CVE-2024-38365 btcd did not correctly re-implement Bitcoin Core's "FindAndDelete()" functionality — btcd 7.4 High2024-10-11
CVE-2024-25622 H2O ignores headers configuration directives — h2o 3.1 Low2024-10-11
CVE-2024-47168 The `enable_monitoring` flag set to `False` does not disable monitoring in Gradio — gradio 7.5AIHighAI2024-10-10
CVE-2024-47763 Wasmtime runtime crash when combining tail calls with trapping imports — wasmtime 5.5 Medium2024-10-09
CVE-2024-45807 oghttp2 crash on OnBeginHeadersForStream in envoy — envoy 7.5 High2024-09-19
CVE-2024-45298 Disabled user can bypass lockout by requesting password reset in wiki.js — wiki 4.3 Medium2024-09-18
CVE-2024-45311 Denial of service in quinn-proto when using `Endpoint::retry()` — quinn 7.5 High2024-09-02
CVE-2024-45304 OwnableTwoStep allows a pending owner to accept ownership after the original owner has renounced ownership in cairo-contracts — cairo-contracts 5.3 Medium2024-08-30
CVE-2024-5659 Rockwell Automation Multicast Request Causes major nonrecoverable fault on Select Controllers — ControlLogix® 5580 6.5AIMediumAI2024-06-14
CVE-2024-37153 Evmos's contract balance not updating correctly after interchain transaction — evmos 7.5 High2024-06-06
CVE-2024-35195 Requests `Session` object does not verify requests after making first request with verify=False — requests 5.6 Medium2024-05-20
CVE-2024-32971 Defect in query plan cache may cause incorrect operations to be executed in Apollo Router — router 9.1 Critical2024-05-02
CVE-2024-0313 Skyhigh Client Proxy 安全漏洞 — Skyhigh Client Proxy 5.5 Medium2024-03-14
CVE-2023-49798 Duplicated execution of subcalls in OpenZeppelin Contracts — openzeppelin-contracts 5.9 Medium2023-12-08
CVE-2023-41338 Vulnerability in Ctx.IsFromLocal() in gofiber — fiber 5.3 Medium2023-09-08
CVE-2023-23623 Content-Secrity-Policy disabling eval not applied consistently in renderers with sandbox disabled in Electron — electron 7.5 High2023-09-06
CVE-2023-41058 Trigger `beforeFind` not invoked in internal query pipeline in parse-server — parse-server 7.5 High2023-09-04
CVE-2023-40015 Vyper: reversed order of side effects for some operations — vyper 3.7 Low2023-09-04
CVE-2023-41052 Vyper: incorrect order of evaluation of side effects for some builtins — vyper 3.7 Low2023-09-04
CVE-2023-32675 Nonpayable default functions are sometimes payable in vyper — vyper 3.7 Low2023-05-19
CVE-2023-30629 Vyper's raw_call with outsize=0 and revert_on_failure=False returns incorrect success value — vyper 7.5 High2023-04-24

Vulnerabilities classified as CWE-670 (控制流实现总是不正确) represent 79 CVEs. The CWE taxonomy describes the weakness; review individual CVEs for product-specific impact.