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-85783 Overview
CVE-2026-85783 is a CPU exhaustion vulnerability in the Crypt::Age module for Perl, affecting versions before 0.004. The flaw allows an attacker to force expensive cryptographic operations by crafting an age-encrypted file with an unbounded number of recipient stanzas. Each stanza triggers an X25519 scalar multiplication, an HKDF derivation, and a ChaCha20-Poly1305 open operation per held identity. Any caller invoking decrypt, decrypt_file, or decrypt_filehandle on an attacker-supplied file is affected. The vulnerability maps to CWE-405: Asymmetric Resource Consumption (Amplification).
Critical Impact
An attacker can send a small file containing many 98-byte recipient stanzas and force the decryptor to perform one scalar multiplication per stanza per identity, exhausting CPU resources on the host.
Affected Products
- Crypt::Age for Perl, all versions before 0.004
- Perl applications calling decrypt, decrypt_file, or decrypt_filehandle on untrusted input
- Downstream distributions bundling vulnerable Crypt::Age releases from CPAN
Discovery Timeline
- 2026-10-20 - CVE-2026-85783 published to NVD
- 2026-10-22 - Last updated in NVD database
Technical Details for CVE-2026-85783
Vulnerability Analysis
The Crypt::Age module implements the age file encryption format in Perl. The header of an age file contains one recipient stanza per intended recipient, and each X25519 stanza encodes 98 bytes of attacker-chosen data. During decryption, unwrap_file_key iterates every held identity against every stanza in the header. For each pair, the function performs an elliptic curve scalar multiplication over X25519, derives a key via HKDF, and attempts a ChaCha20-Poly1305 open.
The parser does not cap the number of stanzas accepted from the header. An attacker-controlled file with thousands of recipient stanzas forces thousands of scalar multiplications before the decryptor can reject the input. The cost scales linearly with the number of stanzas multiplied by the number of identities the caller holds.
Root Cause
The root cause is the absence of an upper bound on recipient stanzas in the header parser combined with the age protocol's requirement to attempt unwrap before verifying the header message authentication code (MAC). The MAC key is itself derived from the file key, which only a successful unwrap produces. The decryptor therefore cannot authenticate the header cheaply before performing the expensive asymmetric operations.
Attack Vector
An attacker crafts an age file containing an inflated number of X25519 recipient stanzas. The attacker then delivers the file to any service, pipeline, or user that decrypts untrusted age content using vulnerable Crypt::Age versions. Processing the file consumes CPU proportional to stanza count and identity count, degrading or stalling the host. No authentication is required and no code execution occurs; impact is limited to availability.
See the OpenWall OSS-Security advisory for the full technical write-up.
Detection Methods for CVE-2026-85783
Indicators of Compromise
- Perl processes consuming sustained high CPU inside Crypt::Age::unwrap_file_key or related X25519 code paths
- Age-encrypted files with unusually large headers or thousands of recipient stanzas
- Repeated decryption failures accompanied by long processing times on specific inputs
Detection Strategies
- Monitor process-level CPU time for Perl workers that handle user-supplied encrypted files and alert on outliers
- Inspect inbound age files and flag any whose header exceeds a reasonable stanza count before invoking the decryptor
- Log the duration of each decrypt, decrypt_file, and decrypt_filehandle call and alert on calls that run beyond a baseline threshold
Monitoring Recommendations
- Track CPU utilization and request latency for services that decrypt untrusted age files
- Record the size of age file headers at the ingestion boundary for later anomaly analysis
- Correlate decryption-service slowdowns with the source of the input file to identify abusive senders
How to Mitigate CVE-2026-85783
Immediate Actions Required
- Upgrade Crypt::Age to version 0.004 or later on every host that decrypts untrusted age files
- Audit Perl code for calls to decrypt, decrypt_file, and decrypt_filehandle that operate on externally sourced data
- Apply input-size limits at the service boundary to reject age files whose headers contain an unreasonable number of stanzas
Patch Information
The maintainer resolved the issue in Crypt::Age version 0.004. Install the fixed release from CPAN and verify the installed version in every Perl environment. Release details are documented in the MetaCPAN Crypt-Age Change Log.
Workarounds
- Reject age files larger than a defined byte threshold before passing them to the decryptor
- Enforce an application-level cap on recipient stanzas by pre-parsing the header and failing fast when the count exceeds expectations
- Run decryption of untrusted content in sandboxed worker processes with CPU-time limits via ulimit or systemd CPUQuota
# Configuration example: upgrade Crypt::Age and constrain the decryption worker
cpanm Crypt::Age@0.004
# systemd unit snippet to cap CPU for a decryption service
# /etc/systemd/system/age-decrypt.service.d/limits.conf
[Service]
CPUQuota=50%
MemoryMax=512M
TimeoutStartSec=30
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

