CVE-2023-25581
| Severity | 9.2 Critical CVSS 4.0 |
|---|---|
| Fixed in | 4.0.0 |
| Weakness | Deserialization of untrusted data (CWE-502) |
| Published | 10 Oct 2024 |
| Updated | 17 Jun 2026 |
Description
pac4j is a security framework for Java. pac4j-core prior to version 4.0.0 is affected by a Java deserialization vulnerability. The vulnerability affects systems that store externally controlled values in attributes of the UserProfile class from pac4j-core. It can be exploited by providing an attribute that contains a serialized Java object with a special prefix {#sb64} and Base64 encoding. This issue may lead to Remote Code Execution (RCE) in the worst case. Although a RestrictedObjectInputStream is in place, that puts some restriction on what classes can be deserialized, it still allows a broad range of java packages and potentially exploitable with different gadget chains. pac4j versions 4.0.0 and greater are not affected by this issue. Users are advised to upgrade. There are no known workarounds for this vulnerability.
Exploitation status
Proof of concept only
A proof of concept exists, but no reviewed exploit catalogue lists this CVE.
Exploitation status
- CISA KEV not listed
- VulnCheck KEV not listed
- CISA Vulnrichment exploitation: poc CISA recorded that an exploit has been demonstrated. Automatable: yes, technical impact: total.
- Indexed PoC none indexed
- EPSS 1.9% chance in 30 days
Waratek protection
Waratek has a rule that blocks attacks on this vulnerability.
- Protection full Deserialization, Process
- Action available security rule
- Review automated Inferred
- Record active
| Decided by | A vulnerability class already blocked by an ARMR security rule |
|---|---|
| Finding | Protected by Waratek's ARMR deserialization security rule, which blocks this class of attack at the JVM level without a rule written for this CVE specifically. The CVE's weakness is CWE-502: Deserialization of Untrusted Data. |
How to mitigate CVE-2023-25581
Upgrade the affected software to 4.0.0 or later. Until you can, Waratek RASP blocks exploitation with its deserialization and process rules. It runs inside the Java application, with no code changes.
Affected software and releases
Maven packages
Affected and fixed versions, from OSV.dev| Package | Introduced | Fixed | Last affected |
|---|---|---|---|
org.pac4j:pac4j-core |
0 | 4.0.0 |
unbounded |
Products and versions
1 product, 1 version entry| Source | Vendor | Product | Scheme | Affected versions |
|---|---|---|---|---|
| osv | org.pac4j | pac4j-core | generic | < 4.0.0 |
References
Timeline
Timeline
| Published | 2024-10-10 | By the CVE Program. |
|---|---|---|
| NVD record modified | 2026-06-17 | NVD's own last-modified date for this record. |