Umbra Wiki weakness weakness/CWE-783
Back to wiki

CWE-783 — Operator Precedence Logic Error

provenance: imported · CWE: CWE-783

CWE-783: Operator Precedence Logic Error

MITRE CWE weakness

Kind Weakness
Abstraction Base
Status Draft
Likelihood of exploit Low

Description

The product uses an expression in which operator precedence causes incorrect logic to be used.

While often just a bug, operator precedence logic errors can have serious consequences if they are used in security-critical code, such as making an authentication decision.

Common consequences

  • Confidentiality, Integrity, Availability: Varies by Context, Unexpected State

Mitigations

Implementation — Regularly wrap sub-expressions in parentheses, especially in security-critical code.

References

  • CWE page: https://cwe.mitre.org/data/definitions/783.html
  • CWE list: https://cwe.mitre.org/data/index.html