If a header file with the same name as one of the standard headers a standard file name is placed in the typical search path to search for libraries then for included source files, the behavior is undefined.
Non-Compliant Example
Naming a header file in the standard library search path any of the following could cause problemsThe standard headers are:
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
Risk Assessment
It is possible that an attacker could place a duplicate header file in the library path in order to cause exploit behavior.
Rule | Severity | Likelihood | Remediation Cost | Priority | Level |
---|---|---|---|---|---|
PRE04-A | 2 1 (mediumlow) | 1 (unlikely) | 3 (low) | P2 P3 | L2 L3 |
References
Wiki Markup |
---|
\[[ISO/IEC 9899-1999:TC2|AA. C References#ISO/IEC 9899-1999TC2]\] Section 7.1.2, "Standard Headers" |