CWE-234

Failure to Handle Missing Parameter
AI Translation Available

If too few arguments are sent to a function, the function will still pop the expected number of arguments from the stack. Potentially, a variable number of arguments could be exhausted in a function as well.

Status
incomplete
Abstraction
variant
Likelihood
high

Common Consequences

integrity confidentiality availability access control
Impacts
execute unauthorized code or commands gain privileges or assume identity dos: crash, exit, or restart

Potential Mitigations

Phases:
build and compilation implementation
Descriptions:
• Forward declare all functions. This is the recommended solution. Properly forward declaration of all used functions will result in a compiler error if too few arguments are sent to a function.
• This issue can be simply combated with the use of proper build process.