The product has two different sources of the same data or information, but it uses the source that has less support for verification, is less trusted, or is less resistant to attack.
Nature | Mapping | Type | ID | Name |
---|---|---|---|---|
ChildOf | Discouraged | C | 345 | Insufficient Verification of Data Authenticity |
Nature | Mapping | Type | ID | Name |
---|---|---|---|---|
MemberOf | Prohibited | V | 884 | CWE Cross-section |
MemberOf | Prohibited | C | 975 | SFP Secondary Cluster: Architecture |
MemberOf | Prohibited | C | 1214 | Data Integrity Issues |
MemberOf | Prohibited | C | 1411 | Comprehensive Categorization: Insufficient Verification of Data Authenticity |
Nature | Mapping | Type | ID | Name |
---|---|---|---|---|
MemberOf | Prohibited | BS | BOSS-294 | Not Language-Specific Weaknesses |
MemberOf | Prohibited | BS | BOSS-316 | Bypass Protection Mechanism (impact) |
MemberOf | Prohibited | BS | BOSS-332 | Gain Privileges or Assume Identity (impact) |
Nature | Mapping | Type | ID | Name |
---|---|---|---|---|
MemberOf | Prohibited | C | 1214 | Data Integrity Issues |
Nature | Mapping | Type | ID | Name |
---|---|---|---|---|
MemberOf | Prohibited | C | 975 | SFP Secondary Cluster: Architecture |
Scope | Likelihood | Impact | Note |
---|---|---|---|
Access Control | N/A | Bypass Protection MechanismGain Privileges or Assume Identity | An attacker could utilize the untrusted data source to bypass protection mechanisms and gain access to sensitive data. |
An attacker could utilize the untrusted data source to bypass protection mechanisms and gain access to sensitive data.
N/A
N/A
This code attempts to limit the access of a page to certain IP Addresses. It checks the 'HTTP_X_FORWARDED_FOR' header in case an authorized user is sending the request through a proxy.
The 'HTTP_X_FORWARDED_FOR' header can be user controlled and so should never be trusted. An attacker can falsify the header to gain access to the page.
This fixed code only trusts the 'REMOTE_ADDR' header and so avoids the issue:
Be aware that 'REMOTE_ADDR' can still be spoofed. This may seem useless because the server will send the response to the fake address and not the attacker, but this may still be enough to conduct an attack. For example, if the generatePage() function in this code is resource intensive, an attacker could flood the server with fake requests using an authorized IP and consume significant resources. This could be a serious DoS attack even though the attacker would never see the page's sensitive content.
Reference | Description |
---|---|
CVE-2001-0860 | Product uses IP address provided by a client, instead of obtaining it from the packet headers, allowing easier spoofing. |
CVE-2004-1950 | Web product uses the IP address in the X-Forwarded-For HTTP header instead of a server variable that uses the connecting IP address, allowing filter bypass. |
CVE-2001-0908 | Product logs IP address specified by the client instead of obtaining it from the packet headers, allowing information hiding. |
CVE-2006-1126 | PHP application uses IP address from X-Forwarded-For HTTP header, instead of REMOTE_ADDR. |
Ordinality | Description |
---|
This CWE entry is at the Base level of abstraction, which is a preferred level of abstraction for mapping to the root causes of vulnerabilities.
Carefully read both the name and description to ensure that this mapping is an appropriate fit. Do not try to 'force' a mapping to a lower-level Base/Variant simply to comply with this preferred level of abstraction.
Taxonomy Name | Entry ID | Fit | Entry Name |
---|---|---|---|
PLOVER | N/A | N/A | Use of Less Trusted Source |