Các cách xuất hiện
Requirements : To reduce risk of vulnerabilities, the developer -
or customers - may wish to restrict or eliminate use of
a function, library, or third party component for any
number of reasons, including real or suspected
vulnerabilities; difficulty to use securely; export
controls or license requirements; obsolete or
poorly-maintained code; internal code being scheduled
for deprecation; etc. This might be achieved using a
list of "banned" functions that programmers must avoid
using, because the functions are difficult or impossible
to use securely.
Implementation
Nền tảng áp dụng
Ngôn ngữ
Lớp: Not Language-Specific (Undetermined)
Hậu quả phổ biến
| Phạm vi |
Tác động |
Khả năng xảy ra |
| Other | Reduce Maintainability
Ghi chú: This issue can also make the product more costly and difficult to maintain. | |
Ví dụ đã quan sát
| Tài liệu tham khảo |
Mô tả |
| Library has multiple buffer overflows using sprintf() and strcpy() |
| FTP client uses inherently insecure gets() function and is setuid root on some systems, allowing buffer overflow |
Các biện pháp giảm thiểu tiềm năng
Phases : Build and Compilation // Implementation
Identify a list of prohibited API functions and prohibit developers from using these functions, providing safer alternatives. In some cases, automatic code analysis tools or the compiler can be instructed to spot use of prohibited functions, such as the "banned.h" include file from Microsoft's SDL. [REF-554] [REF-1009] [REF-7]
Phương pháp phát hiện
Automated Static Analysis
Automated static analysis, commonly referred to as Static Application Security Testing (SAST), can find some instances of this weakness by analyzing source code (or binary/compiled code) without having to execute it. Typically, this is done by building a model of data flow and control flow, then searching for potentially-vulnerable patterns that connect "sources" (origins of input) with "sinks" (destinations where the data interacts with external components, a lower layer such as the OS, etc.)
Hiệu quả : High
Ghi chú ánh xạ lỗ hổng
Lý do : This CWE entry is a Class and might have Base-level children that would be more appropriate
Bình luận : Examine children of this entry to see if there is a better fit
Tài liệu tham khảo
REF-554
Security Development Lifecycle (SDL) Banned Function Calls
Michael Howard.
https://learn.microsoft.com/en-us/previous-versions/bb288454(v=msdn.10)?redirectedfrom=MSDN REF-1009
Microsoft's Free Security Tools - banned.h
Tim Rains.
https://www.microsoft.com/en-us/security/blog/2012/08/30/microsofts-free-security-tools-banned-h/ REF-7
Writing Secure Code
Michael Howard, David LeBlanc.
https://www.microsoftpressstore.com/store/writing-secure-code-9780735617223
Gửi
| Tên |
Tổ chức |
Ngày |
Ngày phát hành |
Version |
| CWE Content Team |
MITRE |
2019-01-03 +00:00 |
2019-01-03 +00:00 |
3.2 |
Sửa đổi
| Tên |
Tổ chức |
Ngày |
Bình luận |
| CWE Content Team |
MITRE |
2020-02-24 +00:00 |
updated References, Relationships |
| CWE Content Team |
MITRE |
2023-01-31 +00:00 |
updated Description |
| CWE Content Team |
MITRE |
2023-04-27 +00:00 |
updated References, Relationships, Time_of_Introduction |
| CWE Content Team |
MITRE |
2023-06-29 +00:00 |
updated Mapping_Notes |
| CWE Content Team |
MITRE |
2024-02-29 +00:00 |
updated Demonstrative_Examples, Observed_Examples |
| CWE Content Team |
MITRE |
2025-12-11 +00:00 |
updated Applicable_Platforms, Detection_Factors |
| CWE Content Team |
MITRE |
2026-04-30 +00:00 |
updated Potential_Mitigations, References |
| CWE Content Team |
MITRE |
2026-10-28 +00:00 |
updated Common_Consequences, Description, Modes_of_Introduction, Time_of_Introduction |