Dark Mode
Capec-39 Detail
Manipulating Opaque Client-based Data Tokens
Standard Software Likelihood: High Typical Severity: Medium
Parents: 22
Children: 31
Threats: T271 T293
Not present
| External ID | Source | Link | Description |
|---|---|---|---|
| CAPEC-39 | capec | https://capec.mitre.org/data/definitions/39.html | |
| CWE-353 | cwe | http://cwe.mitre.org/data/definitions/353.html | |
| CWE-285 | cwe | http://cwe.mitre.org/data/definitions/285.html | |
| CWE-302 | cwe | http://cwe.mitre.org/data/definitions/302.html | |
| CWE-472 | cwe | http://cwe.mitre.org/data/definitions/472.html | |
| CWE-565 | cwe | http://cwe.mitre.org/data/definitions/565.html | |
| CWE-315 | cwe | http://cwe.mitre.org/data/definitions/315.html | |
| CWE-539 | cwe | http://cwe.mitre.org/data/definitions/539.html | |
| CWE-384 | cwe | http://cwe.mitre.org/data/definitions/384.html | |
| CWE-233 | cwe | http://cwe.mitre.org/data/definitions/233.html |
Explore
-
Enumerate information passed to client side: The attacker identifies the parameters used as part of tokens to take business or security decisions
-
Determine protection mechanism for opaque token: The attacker determines the protection mechanism used to protect the confidentiality and integrity of these data tokens. They may be obfuscated or a full blown encryption may be used.
| Techniques |
|---|
| Use WebScarab to reveal hidden fields while browsing. |
| Use a sniffer to capture packets |
| View source of web page to find hidden fields |
| Examine URL to see if any opaque tokens are in it |
| Disassemble or decompile client-side application |
| Use debugging tools such as File Monitor, Registry Monitor, Debuggers, etc. |
| Techniques |
|---|
| Look for signs of well-known character encodings |
| Look for cryptographic signatures |
| Look for delimiters or other indicators of structure |
Experiment
-
Modify parameter/token values: Trying each parameter in turn, the attacker modifies the values
-
Cycle through values for each parameter.: Depending on the nature of the application, the attacker now cycles through values of each parameter and observes the effects of this modification in the data returned by the server
| Techniques |
|---|
| Modify tokens logically |
| Modify tokens arithmetically |
| Modify tokens bitwise |
| Modify structural components of tokens |
| Modify order of parameters/tokens |
| Techniques |
|---|
| Use network-level packet injection tools such as netcat |
| Use application-level data modification tools such as Tamper Data, WebScarab, TamperIE, etc. |
| Use modified client (modified by reverse engineering) |
| Use debugging tools to modify data in client |
- An attacker already has some access to the system or can steal the client based data tokens from another user who has access to the system.
- For an Attacker to viably execute this attack, some data (later interpreted by the application) must be held client-side in a way that can be manipulated without detection. This means that the data or tokens are not CRCd as part of their value or through a separate meta-data store elsewhere.
- The Attacker needs no special hardware-based resources in order to conduct this attack. Software plugins, such as Tamper Data for Firefox, may help in manipulating URL- or cookie-based data.
| High | Medium |
|---|---|
| If the client site token is encrypted. | |
| If the client site token is obfuscated. |
| Integrity | Authorization | Access Control | Confidentiality |
|---|---|---|---|
| Modify Data | Gain Privileges | Gain Privileges | Gain Privileges |
- With certain price watching websites, that aggregate products available prices, the user can buy items through whichever vendors has product availability, the best price, or other differentiator. Once a user selects an item, the site must broker the purchase of that item with the vendor. Because vendors sell the same product through different channel partners at different prices, token exchange between price watching sites and selling vendors will often contain pricing information. With some price watching sites, manipulating URL-data (which is encrypted) even opaquely yields different prices charged by the fulfilling vendor. If the manipulated price turns out higher, the Attacker can cancel purchase. If the Attacker succeeded in manipulating the token and creating a lower price, they proceed.
- Upon successful authentication user is granted an encrypted authentication cookie by the server and it is stored on the client. One piece of information stored in the authentication cookie reflects the access level of the user (e.g. "u" for user). The authentication cookie is encrypted using the Electronic Code Book (ECB) mode, that naively encrypts each of the plaintext blocks to each of the ciphertext blocks separately. An attacker knows the structure of the cookie and can figure out what bits (encrypted) store the information relating to the access level of the user. An attacker modifies the authentication cookie and effectively substitutes "u" for "a" by flipping some of the corresponding bits of ciphertext (trial and error). Once the correct "flip" is found, when the system is accessed, the attacker is granted administrative privileges in the system. Note that in this case an attacker did not have to figure out the exact encryption algorithm or find the secret key, but merely exploit the weakness inherent in using the ECB encryption mode.
- Archangel Weblog 0.90.02 allows remote attackers to bypass authentication by setting the ba_admin cookie to 1. See also: CVE-2006-0944