CAPEC-74: Manipulating State
Description
The adversary modifies state information maintained by the target software or causes a state transition in hardware. If successful, the target will use this tainted state and execute in an unintended manner. State management is an important function within a software application. User state maintained by the application can include usernames, payment information, browsing history as well as application-specific contents such as items in a shopping cart. Manipulating user state can be employed by an adversary to elevate privilege, conduct fraudulent transactions or otherwise modify the flow of the application to derive certain benefits. If there is a hardware logic error in a finite state machine, the adversary can use this to put the system in an undefined state which could cause a denial of service or exposure of secure data.
- Likelihood of attack
- Medium
- Typical severity
- High
- Abstraction
- MetaA decidedly abstract characterisation of a methodology or technique.
Mechanism of attack: Manipulate Timing and State
Prerequisites
- User state is maintained at least in some way in user-controllable locations, such as cookies or URL parameters.
- There is a faulty finite state machine in the hardware logic that can be exploited.
Skills required
- MediumThe adversary needs to have knowledge of state management as employed by the target application, and also the ability to manipulate the state in a meaningful way.
Consequences
- ConfidentialityAccess ControlAuthorization
Gain Privileges
- Integrity
Modify Data
- Availability
Unreliable Execution
Mitigations
- Do not rely solely on user-controllable locations, such as cookies or URL parameters, to maintain user state.
- Avoid sensitive information, such as usernames or authentication and authorization information, in user-controllable locations.
- Sensitive information that is part of the user state must be appropriately protected to ensure confidentiality and integrity at each request.
- All possible states must be handled by hardware finite state machines.
Related weaknesses (CWE)
- CWE-315Cleartext Storage of Sensitive Information in a Cookie
- CWE-353Missing Support for Integrity Check
- CWE-372Incomplete Internal State Distinction
- CWE-693Protection Mechanism Failure
- CWE-1245Improper Finite State Machines (FSMs) in Hardware Logic
- CWE-1253Incorrect Selection of Fuse Values
- CWE-1265Unintended Reentrant Invocation of Non-reentrant Code Via Nested Calls
- CWE-1271Uninitialized Value on Reset for Registers Holding Security Settings