目标达成 感谢每一位支持者 — 我们达成了 100% 目标!

目标: 1000 元 · 已筹: 1336

100%

CWE-259 使用硬编码的口令 类漏洞列表 126

CWE-259 使用硬编码的口令 类弱点 126 条 CVE 漏洞汇总,含 AI 中文分析。

CWE-259 指软件在入站认证或出站通信中硬编码密码的漏洞。攻击者常通过逆向工程提取源码中的明文凭证,进而伪装合法用户或横向渗透外部系统。开发者应避免此类做法,改用环境变量、密钥管理服务或配置文件存储敏感信息,确保密码动态生成且与代码分离,从而降低凭证泄露风险。

MITRE CWE 官方描述
CWE:CWE-259 使用硬编码密码 (Use of Hard-coded Password) 英文:该产品包含一个硬编码密码 (hard-coded password),用于其自身的入站认证 (inbound authentication) 或与外部组件进行出站通信 (outbound communication)。 硬编码密码 (hard-coded password) 主要有两种变体:入站 (Inbound):该产品包含一种认证机制,用于检查硬编码密码 (hard-coded password)。出站 (Outbound):该产品连接到另一个系统或组件,并包含用于连接该组件的硬编码密码 (hard-coded password)。
常见影响 (2)
Access Control Gain Privileges or Assume Identity
If hard-coded passwords are used, it is almost certain that malicious users can gain access through the account in question.
Access Control Gain Privileges or Assume Identity, Hide Activities, Reduce Maintainability
A hard-coded password typically leads to a significant authentication failure that can be difficult for the system administrator to detect. Once detected, it can be difficult to fix, so the administrator may be forced into disabling the product entirely.
缓解措施 (5)
Architecture and Design For outbound authentication: store passwords outside of the code in a strongly-protected, encrypted configuration file or database that is protected from access by all outsiders, including other local users on the same system. Properly protect the key (CWE-320). If you cannot use encryption to protect the file, then make sure that the permissions are as restrictive as possible.
Architecture and Design For inbound authentication: Rather than hard-code a default username and password for first time logins, utilize a "first login" mode that requires the user to enter a unique strong password.
Architecture and Design Perform access control checks and limit which entities can access the feature that requires the hard-coded password. For example, a feature might only be enabled through the system console instead of through a network connection.
Architecture and Design For inbound authentication: apply strong one-way hashes to your passwords and store those hashes in a configuration file or database with appropriate access control. That way, theft of the file/database still requires the attacker to try to crack the password. When receiving an incoming password during authentication, take the hash of the password and compare it to the hash that you have saved. Us…
Architecture and Design For front-end to back-end connections: Three solutions are possible, although none are complete. The first suggestion involves the use of generated passwords which are changed automatically and must be entered at given time intervals by a system administrator. These passwords will be held in memory and only be valid for the time intervals. Next, the passwords used should be limited at the back end…
代码示例 (2)
The following code uses a hard-coded password to connect to a database:
... DriverManager.getConnection(url, "scott", "tiger"); ...
Bad · Java
javap -c ConnMngr.class 22: ldc #36; //String jdbc:mysql://ixne.com/rxsql 24: ldc #38; //String scott 26: ldc #17; //String tiger
Attack
The following code is an example of an internal hard-coded password in the back-end:
int VerifyAdmin(char *password) { if (strcmp(password, "Mew!")) { printf("Incorrect Password!\n"); return(0); } printf("Entering Diagnostic Mode...\n"); return(1); }
Bad · C
int VerifyAdmin(String password) { if (!password.equals("Mew!")) { return(0); } //Diagnostic Mode return(1); }
Bad · Java
CVE ID 标题 CVSS 风险等级 Published
CVE-2024-34025 Cyber Power Systems PowerPanel Business Edition 安全漏洞 — PowerPanel business 9.8 Critical 2024-05-15
CVE-2024-32741 Siemens SIMATIC CN 4100 安全漏洞 — SIMATIC CN 4100 10.0 Critical 2024-05-14
CVE-2023-51629 D-Link DCS-8300LHV2 安全漏洞 — DCS-8300LHV2 8.8 - 2024-05-03
CVE-2023-32145 D-Link DAP-1360 安全漏洞 — DAP-1360 8.8 - 2024-05-03
CVE-2024-29011 SonicWALL GMS 安全漏洞 — GMS 7.5 High 2024-05-01
CVE-2024-21990 NetApp ONTAP Select Deploy administration utility 安全漏洞 — ONTAP Select Deploy administration utility 5.4 Medium 2024-04-17
CVE-2024-28010 NEC Corporation Aterm 安全漏洞 — WG1800HP4 6.8AI Medium AI 2024-03-28
CVE-2024-2197 Chirp Access 信任管理问题漏洞 — Chirp Access 4.3 Medium 2024-03-19
CVE-2024-27774 Unitronics Unistream Unilogic 安全漏洞 — Unistream Unilogic 7.5 High 2024-03-18
CVE-2024-26196 Microsoft Edge 漏洞 — Microsoft Edge for Android 4.3 Medium 2024-02-29
CVE-2023-50948 IBM Storage Fusion 安全漏洞 — Storage Fusion HCI 6.5 Medium 2024-01-08
CVE-2023-28895 Škoda Modular Infotainment Platform 3 安全漏洞 — MIB3 Infotainment Unit 3.5 Low 2023-12-01
CVE-2023-41713 SonicWALL SonicOS 信任管理问题漏洞 — SonicOS 9.8 - 2023-10-17
CVE-2023-5222 Viessmann Vitogate 安全漏洞 — Vitogate 300 6.3 Medium 2023-09-27
CVE-2023-41030 Juplink RX4-1500 信任管理问题漏洞 — RX4-1500 6.3 Medium 2023-09-18
CVE-2023-23771 Motorola MBTS Base Radio 信任管理问题漏洞 — MBTS Base Radio 8.4 High 2023-08-29
CVE-2023-23770 Motorola MBTS Site Controller 信任管理问题漏洞 — MBTS Site Controller 9.4 Critical 2023-08-29
CVE-2023-3237 OTCMS 信任管理问题漏洞 — OTCMS 6.3 Medium 2023-06-14
CVE-2023-2061 Mitsubishi Electric MELSEC 信任管理问题漏洞 — MELSEC iQ-R Series EtherNet/IP module RJ71EIP91 6.2 Medium 2023-06-02
CVE-2023-1944 Minikube 信任管理问题漏洞 — minikube 8.4 High 2023-05-24
CVE-2023-2799 cnoa OA 安全漏洞 — OA 6.3 Medium 2023-05-18
CVE-2023-2645 USR IOT 4G LTE Industrial Cellular VPN Router 安全漏洞 — USR-G806 9.8 Critical 2023-05-11
CVE-2023-29103 Siemens SIMATIC Cloud Connect 安全漏洞 — SIMATIC Cloud Connect 7 CC712 4.3 Medium 2023-05-09
CVE-2023-0808 NingBo Deye Inverter Technology Deye/Revolt/Bosswerk Inverter 信任管理问题漏洞 — Inverter 3.9 Low 2023-02-13
CVE-2022-45444 Sewio Real-Time Location System (RTLS) Studio 信任管理问题漏洞 — RTLS Studio 10.0 Critical 2023-01-18
CVE-2018-25069 Netis Netcore Router 安全漏洞 — Netcore Router 7.3 High 2023-01-07
CVE-2014-125030 Empress 信任管理问题漏洞 — Empress 6.3 Medium 2023-01-01
CVE-2022-41653 DAIKIN SVMPC1 和 SVMPC2 信任管理问题漏洞 — SVMPC1 9.8 Critical 2022-12-13
CVE-2022-29831 Mitsubishi Electric GX Works3 信任管理问题漏洞 — GX Works3 7.5 High 2022-11-24
CVE-2022-29825 Mitsubishi Electric GX Works3 信任管理问题漏洞 — GX Works3 5.6 Medium 2022-11-24

CWE-259(使用硬编码的口令) 是常见的弱点类别,本平台收录该类弱点关联的 126 条 CVE 漏洞。