1690
Example Language: (Attack)
../../../etc/passwd
will have the first "../" filtered, resulting in:
Example Language: (Result)
../../etc/passwd
This value is then concatenated with the /home/user/ directory:
Example Language: (Result)
/home/user/../../etc/passwd
which causes the /etc/passwd file to be retrieved once the operating system has resolved the ../
sequences in the pathname. This leads to relative path traversal (CWE-22).
MemberOf Relationships
This MemberOf relationships table shows additional CWE Catgeories and Views that reference this
weakness as a member. This information is often useful in understanding where a weakness fits
within the context of external information sources.
Nature Type ID Name Page
MemberOf 1407 Comprehensive Categorization: Improper Neutralization 1400 2532
CWE-798: Use of Hard-coded Credentials
Weakness ID : 798
Structure : Simple
Abstraction : Base
Description
The product contains hard-coded credentials, such as a password or cryptographic key, which
it uses for its own inbound authentication, outbound communication to external components, or
encryption of internal data.
Extended Description
Hard-coded credentials typically create a significant hole that allows an attacker to bypass the
authentication that has been configured by the product administrator. This hole might be difficult
for the system administrator to detect. Even if detected, it can be difficult to fix, so the administrator
may be forced into disabling the product entirely. There are two main variations:
Inbound: the product contains an authentication mechanism that checks the input credentials
against a hard-coded set of credentials.
Outbound: the product connects to another system or component, and it contains hard-coded
credentials for connecting to that component.
In the Inbound variant, a default administration account is created, and a simple password is
hard-coded into the product and associated with that account. This hard-coded password is the
same for each installation of the product, and it usually cannot be changed or disabled by system
administrators without manually modifying the program, or otherwise patching the product. If the
password is ever discovered or published (a common occurrence on the Internet), then anybody
with knowledge of this password can access the product. Finally, since all installations of the
CWE Version 4.14
CWE-798: Use of Hard-coded Credentials
CWE-798: Use of Hard-coded Credentials