Skip to main content
Vulnerability Database/CVE-2026-97230

CVE-2026-97230: Perl IO::Socket::SSL::SelfCertificate RCE

CVE-2026-97230 is a malicious remote code execution vulnerability in IO::Socket::SSL::SelfCertificate 1.00 for Perl that executes obfuscated Python code from a remote URL. This article covers technical details, impact, and removal.

Published:

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

CVE-2026-97230 Overview

CVE-2026-97230 identifies a malicious Perl distribution published to CPAN as IO::Socket::SSL::SelfCertificate version 1.00. The package contains a dropper that executes arbitrary Python code fetched from a hardcoded, base64-obfuscated HTTP URL. The payload runs under the identity of the user invoking the generate_certificate function, with no script written to disk. The distribution ships no test scripts or build hooks, indicating the author likely intended execution post-installation. This typosquat-style supply chain abuse mirrors CVE-2026-95831, which affected the sibling module Crypt::SelfCertificate. The malicious file is located at lib/Crypt/SelfCertificate/sample/cert.pem inside the archive.

Critical Impact

Any Perl environment that installs and invokes IO::Socket::SSL::SelfCertificate 1.00 will execute attacker-controlled Python code retrieved over an unauthenticated HTTP channel, enabling arbitrary code execution without persistent artifacts.

Affected Products

  • IO::Socket::SSL::SelfCertificate 1.00 (Perl CPAN distribution)
  • Archive IO-Socket-SSL-SelfCertificate-1.00.tar.gz (SHA-256 ba24ee8ec3b7f47f65bed62e16fb413ace50653cf44bd8ea90914390922831e0)
  • Dropper file lib/IO/Socket/SSL/SelfCertificate/sample/cert.pem (SHA-256 821d38830e5eb8607738421c25ac25f59fff02a6ab67daa32fbd020429454dac)

Discovery Timeline

  • 2026-09-24 - CVE-2026-97230 published to NVD
  • 2026-09-25 - Last updated in NVD database

Technical Details for CVE-2026-97230

Vulnerability Analysis

The IO::Socket::SSL::SelfCertificate 1.00 package is not vulnerable software in the traditional sense. It is an intentionally malicious distribution classified under [CWE-506] (Embedded Malicious Code). The package name impersonates the legitimate IO::Socket::SSL ecosystem, increasing the chance that developers or automated build systems install it by mistake. Upon invocation of generate_certificate, the module reads a file named cert.pem and executes its contents as Python rather than parsing it as a certificate.

The loader decodes a base64-obfuscated HTTP URL and performs an outbound request. The response body is passed directly to the Python interpreter without validation, caching, or verification. Because the fetched code is executed in memory, no secondary script is dropped to the filesystem, limiting forensic artifacts. The attacker retains the ability to change the payload at any time by modifying the content served from the hardcoded endpoint.

Root Cause

The root cause is deliberate inclusion of malicious code in a CPAN upload. The dropper masquerades as a sample PEM certificate at lib/Crypt/SelfCertificate/sample/cert.pem while actually containing a Python stager. The absence of any test scripts or build hooks suggests execution was intended to occur after installation, when a user calls the exported generate_certificate routine.

Attack Vector

Exploitation requires an operator or automation pipeline to install the malicious distribution from CPAN and subsequently call generate_certificate. The call triggers the Python interpreter to execute remote code fetched over HTTP from the obfuscated URL. Because the request is network-sourced and runs with the privileges of the Perl process, downstream impact depends on where the module is used, including developer workstations, CI/CD runners, and production hosts. Review the referenced Perl CPAN Testers Discussion and the related CVE-2026-95831 Details for additional context.

Stop Remote Code Execution Before It Runs

Singularity™ Endpoint detects and blocks exploit attempts at machine speed, including zero-days and novel attack techniques.

Stop Exploit Attempts

Detection Methods for CVE-2026-97230

Indicators of Compromise

  • SHA-256 ba24ee8ec3b7f47f65bed62e16fb413ace50653cf44bd8ea90914390922831e0 for the archive IO-Socket-SSL-SelfCertificate-1.00.tar.gz.
  • SHA-256 821d38830e5eb8607738421c25ac25f59fff02a6ab67daa32fbd020429454dac for the embedded dropper cert.pem.
  • SHA-256 d483cb7b23b7271cb11cf242bff4a2e1c02df0b9525eb0429abeea8961c399d5 for the upload archive IO-Socket-SSL-SelfCertificate-1.00-upload.tar.gz.
  • Presence of the path lib/IO/Socket/SSL/SelfCertificate/sample/cert.pem on any host, build agent, or container image.

Detection Strategies

  • Scan Perl library directories and CPAN caches for the module name IO::Socket::SSL::SelfCertificate and version 1.00.
  • Alert when a Perl process spawns python or python3 as a child, especially with input piped via stdin.
  • Detect outbound HTTP requests originating from perl processes to non-corporate destinations shortly after module installation.

Monitoring Recommendations

  • Baseline CPAN installation telemetry across developer workstations and CI runners and flag new or unexpected modules.
  • Capture command-line and parent-process telemetry so that perl -> python execution chains are preserved for investigation.
  • Monitor DNS and HTTP egress for base64-decoded URLs embedded in Perl modules.

How to Mitigate CVE-2026-97230

Immediate Actions Required

  • Remove IO::Socket::SSL::SelfCertificate 1.00 from every system, container image, and CPAN mirror under your control.
  • Rotate any credentials, tokens, or SSH keys accessible to accounts that invoked generate_certificate from this module.
  • Treat affected hosts as compromised and perform full incident response, including memory forensics, before returning them to service.

Patch Information

No patched version exists. The distribution is malicious by design and should not be reinstalled. Use the legitimate IO::Socket::SSL module from a trusted maintainer for TLS socket needs, and generate certificates with openssl or Crypt::OpenSSL::CA instead.

Workarounds

  • Pin CPAN installations to an internal, curated mirror that excludes the malicious distribution.
  • Block egress HTTP traffic from build systems and developer endpoints to unapproved destinations.
  • Enforce code review and allow-listing for new third-party Perl dependencies before they reach CI/CD pipelines.
bash
# Verify and remove the malicious distribution
cpanm --uninstall IO::Socket::SSL::SelfCertificate
find / -type f -name 'cert.pem' -path '*IO/Socket/SSL/SelfCertificate/sample/*' -print -delete
sha256sum /path/to/IO-Socket-SSL-SelfCertificate-1.00.tar.gz

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.