Goal Reached Thanks to every supporter — we hit 100%!

Goal: 1000 CNY · Raised: 1000 CNY

100.0%

CWE-502 (可信数据的反序列化) — Vulnerability Class 1698

1698 vulnerabilities classified as CWE-502 (可信数据的反序列化). AI Chinese analysis included.

CWE-502 represents a critical security weakness where applications deserialize untrusted data without validating its integrity or structure. Attackers typically exploit this vulnerability by crafting malicious serialized objects that, when processed by the application, trigger unintended code execution or logic flaws. This often leads to remote code execution, denial of service, or privilege escalation, as the deserialization process may instantiate dangerous classes or invoke unsafe methods. To mitigate this risk, developers must strictly avoid deserializing data from untrusted sources. Instead, they should implement robust input validation, use allowlists for permitted data types, or adopt safer serialization formats like JSON that do not inherently support arbitrary object instantiation. Additionally, employing cryptographic signatures to verify data authenticity before deserialization ensures that only trusted, unaltered payloads are processed, effectively neutralizing the threat of malicious object injection.

MITRE CWE Description
The product deserializes untrusted data without sufficiently ensuring that the resulting data will be valid.
Common Consequences (3)
IntegrityModify Application Data, Unexpected State
Attackers can modify unexpected objects or data that was assumed to be safe from modification. Deserialized data or code could be modified without using the provided accessor functions, or unexpected functions could be invoked.
AvailabilityDoS: Resource Consumption (CPU)
If a function is making an assumption on when to terminate, based on a sentry in a string, it could easily never terminate.
OtherVaries by Context
The consequences can vary widely, because it depends on which objects or methods are being deserialized, and how they are used. Making an assumption that the code in the deserialized object is valid is dangerous and can enable exploitation. One example is attackers using gadget chains to perform una…
Mitigations (5)
Architecture and Design, ImplementationIf available, use the signing/sealing features of the programming language to assure that deserialized data has not been tainted. For example, a hash-based message authentication code (HMAC) could be used to ensure that data has not been modified.
ImplementationWhen deserializing data, populate a new object rather than just deserializing. The result is that the data flows through safe input validation and that the functions are safe.
ImplementationExplicitly define a final object() to prevent deserialization.
Architecture and Design, ImplementationMake fields transient to protect them from deserialization. An attempt to serialize and then deserialize a class containing transient fields will result in NULLs where the transient data should be. This is an excellent way to prevent time, environment-based, or sensitive variables from being carried over and used improperly.
ImplementationAvoid having unnecessary types or gadgets (a sequence of instances and method invocations that can self-execute during the deserialization process, often found in libraries) available that can be leveraged for malicious ends. This limits the potential for unintended or unauthorized types and gadgets to be leveraged by the attacker. Add only acceptable classes to an allowlist. Note: new gadgets are…
Examples (2)
This code snippet deserializes an object from a file and uses it as a UI button:
try { File file = new File("object.obj"); ObjectInputStream in = new ObjectInputStream(new FileInputStream(file)); javax.swing.JButton button = (javax.swing.JButton) in.readObject(); in.close(); }
Bad · Java
private final void readObject(ObjectInputStream in) throws java.io.IOException { throw new java.io.IOException("Cannot be deserialized"); }
Good · Java
In Python, the Pickle library handles the serialization and deserialization processes. In this example derived from [REF-467], the code receives and parses data, and afterwards tries to authenticate a user based on validating a token.
try { class ExampleProtocol(protocol.Protocol): def dataReceived(self, data): # Code that would be here would parse the incoming data # After receiving headers, call confirmAuth() to authenticate def confirmAuth(self, headers): try: token = cPickle.loads(base64.b64decode(headers['AuthToken'])) if not check_hmac(token['signature'], token['data'], getSecretKey()): raise AuthFail self.secure_data = token['data'] except: raise AuthFail }
Bad · Python
CVE IDTitleCVSSSeverityPublished
CVE-2023-25581 Deserialization of untrusted data in InternalAttributeHandler in pac4j — pac4j 9.8AICriticalAI2024-10-10
CVE-2024-9005 Schneider Electric EcoStruxure Power Monitoring Expert 代码问题漏洞 — EcoStruxure Power Monitoring Expert (PME) 9.8AICriticalAI2024-10-08
CVE-2024-9314 Rank Math SEO – AI SEO Tools to Dominate SEO Rankings <= 1.0.228 - Authenticated (Administrator+) PHP Object Injection — Rank Math SEO – AI SEO Tools to Dominate SEO Rankings 7.2 High2024-10-05
CVE-2024-47561 Apache Avro Java SDK: Arbitrary Code Execution when reading Avro schema (Java SDK) — Apache Avro Java SDK 9.8 -2024-10-03
CVE-2024-7434 UltraPress <= 1.2.2 - Authenticated (Contributor+) PHP Object Injection — UltraPress 8.8 High2024-10-01
CVE-2024-7433 Empowerment <= 1.0.2 - Authenticated (Contributor+) PHP Object Injection — Empowerment 8.8 High2024-10-01
CVE-2024-7432 Unseen Blog <= 1.0.0 - Authenticated (Contributor+) PHP Object Injection — Unseen Blog 8.8 High2024-10-01
CVE-2024-45772 Apache Lucene Replicator: Security Vulnerability in Lucene Replicator - Deserialization Issue — Apache Lucene Replicator 5.1 Medium2024-09-30
CVE-2024-8353 GiveWP – Donation Plugin and Fundraising Platform <= 3.16.1 - Unauthenticated PHP Object Injection — GiveWP – Donation Plugin and Fundraising Platform 9.8 Critical2024-09-28
CVE-2024-8922 Product Enquiry for WooCommerce <= 2.2.33.33 - Authenticated (Author+) PHP Object Injection in enquiry_detail.php — PiWeb Product Enquiry or product catalog for WooCommerce 8.8 High2024-09-27
CVE-2024-43191 IBM ManageIQ command execution — Cloud Pak for Multicloud Management 7.2 High2024-09-26
CVE-2024-8316 Progress UI for WPF format provider unsafe deserialization vulnerability — Telerik UI for WPF 7.8 High2024-09-25
CVE-2024-7576 Progress UI for WPF format provider unsafe deserialization vulnerability — Telerik UI for WPF 7.8 High2024-09-25
CVE-2024-8514 Prisna GWT - Google Website Translator <= 1.4.11 - Authenticated (Admin+) PHP Object Injection — Prisna GWT – Google Website Translator 9.1 Critical2024-09-25
CVE-2022-2439 Easy Digital Downloads – Simple eCommerce for Selling Digital Files <= 3.3.3 - Authenticated (Admin+) PHAR Deserialization — Easy Digital Downloads – eCommerce Payments and Subscriptions made easy 7.2 High2024-09-24
CVE-2024-42323 Apache HertzBeat: RCE by snakeYaml deser load malicious xml — Apache HertzBeat 8.8 -2024-09-21
CVE-2024-8375 Object deserialization in Reverb leading to RCE — Reverb 9.1AICriticalAI2024-09-19
CVE-2024-5998 Deserialization of Untrusted Data in langchain-ai/langchain — langchain-ai/langchain 9.8 -2024-09-17
CVE-2024-22399 Apache Seata: Remote Code Execution vulnerability via Hessian Deserialization in Apache Seata Server — Apache Seata 9.8 -2024-09-16
CVE-2024-8862 h2oai h2o-3 JDBC Connection 1 getConnectionSafe deserialization — h2o-3 7.3 High2024-09-14
CVE-2022-2446 WP Editor <= 1.2.9 - Authenticated (Admin+) PHAR Deserialization — WP Editor 7.2 High2024-09-13
CVE-2024-41874 ColdFusion | Deserialization of Untrusted Data (CWE-502) — ColdFusion 9.8 Critical2024-09-13
CVE-2024-28991 SolarWinds Access Rights Manager (ARM) Deserialization of Untrusted Data Remote Code Execution — Access Rights Manager 9.0 Critical2024-09-12
CVE-2024-45855 MindsDB 安全漏洞 — mindsdb 7.1 High2024-09-12
CVE-2024-45854 MindsDB 安全漏洞 — mindsdb 7.1 High2024-09-12
CVE-2024-45853 MindsDB 安全漏洞 — mindsdb 7.1 High2024-09-12
CVE-2024-45852 MindsDB 安全漏洞 — mindsdb 8.8 High2024-09-12
CVE-2024-45857 Cleanlab 安全漏洞 — cleanlab 7.8 High2024-09-12
CVE-2024-43466 Microsoft SharePoint Server Denial of Service Vulnerability — Microsoft SharePoint Enterprise Server 2016 6.5 Medium2024-09-10
CVE-2024-43464 Microsoft SharePoint Server Remote Code Execution Vulnerability — Microsoft SharePoint Enterprise Server 2016 7.2 High2024-09-10

Vulnerabilities classified as CWE-502 (可信数据的反序列化) represent 1698 CVEs. The CWE taxonomy describes the weakness; review individual CVEs for product-specific impact.