CVE-2019-1010161

9.8 CRITICAL

📋 TL;DR

This vulnerability in perl-Crypt-JWT allows attackers to bypass authentication by crafting malicious JWT tokens. It affects any application using perl-Crypt-JWT version 0.022 or earlier for JWT-based authentication. Attackers can forge valid tokens without proper cryptographic verification.

💻 Affected Systems

Products:
  • perl-Crypt-JWT
Versions: 0.022 and earlier
Operating Systems: All operating systems running Perl
Default Config Vulnerable: ⚠️ Yes
Notes: Any Perl application using Crypt-JWT for JWT token validation is affected regardless of configuration.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete system compromise through unauthorized access to protected resources, data exfiltration, and privilege escalation across all services using JWT authentication.

🟠

Likely Case

Unauthorized access to protected API endpoints, user data exposure, and session hijacking in applications relying on JWT for authentication.

🟢

If Mitigated

Limited impact with proper network segmentation, additional authentication layers, and monitoring for anomalous token usage.

🌐 Internet-Facing: HIGH - Internet-facing applications using JWT authentication are directly vulnerable to unauthenticated attacks.
🏢 Internal Only: MEDIUM - Internal applications are vulnerable but require network access; risk increases if internal services are interconnected.

🎯 Exploit Status

Public PoC: ⚠️ Yes
Weaponized: LIKELY
Unauthenticated Exploit: ⚠️ Yes
Complexity: LOW

Exploitation requires crafting JWT tokens with specific malformed signatures; public GitHub issue demonstrates the technique.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: 0.023

Vendor Advisory: https://github.com/DCIT/perl-Crypt-JWT/issues/3

Restart Required: No

Instructions:

1. Update perl-Crypt-JWT using CPAN: 'cpan Crypt::JWT' 2. Verify installation with 'perl -MCrypt::JWT -e "print $Crypt::JWT::VERSION"' 3. Ensure version is 0.023 or higher

🔧 Temporary Workarounds

Input Validation Filter

all

Implement custom JWT token validation to reject malformed signatures before processing.

# Perl code snippet to validate token structure
# Check token has proper format before passing to Crypt::JWT

🧯 If You Can't Patch

  • Implement network-level controls to restrict access to JWT-protected endpoints
  • Add secondary authentication factor or session validation

🔍 How to Verify

Check if Vulnerable:

Check installed version: 'perl -MCrypt::JWT -e "print $Crypt::JWT::VERSION"' - if output is 0.022 or lower, system is vulnerable.

Check Version:

perl -MCrypt::JWT -e "print $Crypt::JWT::VERSION"

Verify Fix Applied:

After update, run same command and confirm version is 0.023 or higher.

📡 Detection & Monitoring

Log Indicators:

  • Failed authentication attempts with malformed JWT tokens
  • Successful authentications with unusual token patterns

Network Indicators:

  • HTTP requests with crafted JWT tokens to authentication endpoints
  • Unusual token payload sizes or structures

SIEM Query:

source="application.log" AND ("JWT" OR "token") AND ("malformed" OR "invalid" OR "bypass")

🔗 References

📤 Share & Export