Join the Cyber Forum: Threat Intel on May 12, 2026 to learn how AI is reshaping threat defense.Join the Virtual Cyber Forum: Threat IntelRegister Now
Experiencing a Breach?Blog
Get StartedContact Us
SentinelOne
  • Platform
    Platform Overview
    • Singularity Platform
      Welcome to Integrated Enterprise Security
    • AI for Security
      Leading the Way in AI-Powered Security Solutions
    • Securing AI
      Accelerate AI Adoption with Secure AI Tools, Apps, and Agents.
    • How It Works
      The Singularity XDR Difference
    • Singularity Marketplace
      One-Click Integrations to Unlock the Power of XDR
    • Pricing & Packaging
      Comparisons and Guidance at a Glance
    Data & AI
    • Purple AI
      Accelerate SecOps with Generative AI
    • Singularity Hyperautomation
      Easily Automate Security Processes
    • AI-SIEM
      The AI SIEM for the Autonomous SOC
    • AI Data Pipelines
      Security Data Pipeline for AI SIEM and Data Optimization
    • Singularity Data Lake
      AI-Powered, Unified Data Lake
    • Singularity Data Lake for Log Analytics
      Seamlessly Ingest Data from On-Prem, Cloud or Hybrid Environments
    Endpoint Security
    • Singularity Endpoint
      Autonomous Prevention, Detection, and Response
    • Singularity XDR
      Native & Open Protection, Detection, and Response
    • Singularity RemoteOps Forensics
      Orchestrate Forensics at Scale
    • Singularity Threat Intelligence
      Comprehensive Adversary Intelligence
    • Singularity Vulnerability Management
      Application & OS Vulnerability Management
    • Singularity Identity
      Identity Threat Detection and Response
    Cloud Security
    • Singularity Cloud Security
      Block Attacks with an AI-Powered CNAPP
    • Singularity Cloud Native Security
      Secure Cloud and Development Resources
    • Singularity Cloud Workload Security
      Real-Time Cloud Workload Protection Platform
    • Singularity Cloud Data Security
      AI-Powered Threat Detection for Cloud Storage
    • Singularity Cloud Security Posture Management
      Detect and Remediate Cloud Misconfigurations
    Securing AI
    • Prompt Security
      Secure AI Tools Across Your Enterprise
  • Why SentinelOne?
    Why SentinelOne?
    • Why SentinelOne?
      Cybersecurity Built for What’s Next
    • Our Customers
      Trusted by the World’s Leading Enterprises
    • Industry Recognition
      Tested and Proven by the Experts
    • About Us
      The Industry Leader in Autonomous Cybersecurity
    Compare SentinelOne
    • Arctic Wolf
    • Broadcom
    • CrowdStrike
    • Cybereason
    • Microsoft
    • Palo Alto Networks
    • Sophos
    • Splunk
    • Trellix
    • Trend Micro
    • Wiz
    Verticals
    • Energy
    • Federal Government
    • Finance
    • Healthcare
    • Higher Education
    • K-12 Education
    • Manufacturing
    • Retail
    • State and Local Government
  • Services
    Managed Services
    • Managed Services Overview
      Wayfinder Threat Detection & Response
    • Threat Hunting
      World-Class Expertise and Threat Intelligence
    • Managed Detection & Response
      24/7/365 Expert MDR Across Your Entire Environment
    • Incident Readiness & Response
      DFIR, Breach Readiness, & Compromise Assessments
    Support, Deployment, & Health
    • Technical Account Management
      Customer Success with Personalized Service
    • SentinelOne GO
      Guided Onboarding & Deployment Advisory
    • SentinelOne University
      Live and On-Demand Training
    • Services Overview
      Comprehensive Solutions for Seamless Security Operations
    • SentinelOne Community
      Community Login
  • Partners
    Our Network
    • MSSP Partners
      Succeed Faster with SentinelOne
    • Singularity Marketplace
      Extend the Power of S1 Technology
    • Cyber Risk Partners
      Enlist Pro Response and Advisory Teams
    • Technology Alliances
      Integrated, Enterprise-Scale Solutions
    • SentinelOne for AWS
      Hosted in AWS Regions Around the World
    • Channel Partners
      Deliver the Right Solutions, Together
    • SentinelOne for Google Cloud
      Unified, Autonomous Security Giving Defenders the Advantage at Global Scale
    • Partner Locator
      Your Go-to Source for Our Top Partners in Your Region
    Partner Portal→
  • Resources
    Resource Center
    • Case Studies
    • Data Sheets
    • eBooks
    • Reports
    • Videos
    • Webinars
    • Whitepapers
    • Events
    View All Resources→
    Blog
    • Feature Spotlight
    • For CISO/CIO
    • From the Front Lines
    • Identity
    • Cloud
    • macOS
    • SentinelOne Blog
    Blog→
    Tech Resources
    • SentinelLABS
    • Ransomware Anthology
    • Cybersecurity 101
  • About
    About SentinelOne
    • About SentinelOne
      The Industry Leader in Cybersecurity
    • Investor Relations
      Financial Information & Events
    • SentinelLABS
      Threat Research for the Modern Threat Hunter
    • Careers
      The Latest Job Opportunities
    • Press & News
      Company Announcements
    • Cybersecurity Blog
      The Latest Cybersecurity Threats, News, & More
    • FAQ
      Get Answers to Our Most Frequently Asked Questions
    • DataSet
      The Live Data Platform
    • S Foundation
      Securing a Safer Future for All
    • S Ventures
      Investing in the Next Generation of Security, Data and AI
  • Pricing
Get StartedContact Us
CVE Vulnerability Database
Vulnerability Database/CVE-2025-40905

CVE-2025-40905: WWW::OAuth Perl Weak Entropy Vulnerability

CVE-2025-40905 is a weak entropy vulnerability in WWW::OAuth 1.000 and earlier for Perl that uses insecure rand() function for cryptography, enabling information disclosure. This article covers technical details, impact, and fixes.

Published: February 20, 2026

CVE-2025-40905 Overview

CVE-2025-40905 is an Insecure Random Number Generation vulnerability affecting WWW::OAuth version 1.000 and earlier for Perl. The module uses the rand() function as the default source of entropy for cryptographic functions, which is not cryptographically secure. This weakness can allow attackers to predict OAuth tokens and nonces, potentially leading to authentication bypass or session hijacking in applications relying on this module for OAuth authentication.

Critical Impact

Applications using WWW::OAuth 1.000 or earlier may generate predictable OAuth tokens and nonces, enabling attackers to forge authentication credentials or hijack sessions through predictable random value generation.

Affected Products

  • WWW::OAuth version 1.000
  • WWW::OAuth versions prior to 1.000
  • Perl applications using WWW::OAuth for OAuth authentication

Discovery Timeline

  • 2026-02-13 - CVE-2025-40905 published to NVD
  • 2026-02-17 - Last updated in NVD database

Technical Details for CVE-2025-40905

Vulnerability Analysis

The vulnerability stems from the use of Perl's built-in rand() function for generating cryptographic values in OAuth protocol operations. The rand() function in Perl is designed for general-purpose pseudo-random number generation and is explicitly documented as unsuitable for cryptographic purposes. When used for generating OAuth nonces, tokens, or other security-critical values, the predictable nature of rand() output can be exploited by attackers who understand the underlying algorithm.

OAuth 1.0a requires nonce values to be unique and unpredictable to prevent replay attacks and ensure the integrity of signed requests. By using a non-cryptographic random number generator, the WWW::OAuth module fundamentally undermines this security requirement.

Root Cause

The root cause is the use of CWE-338: Use of Cryptographically Weak Pseudo-Random Number Generator (PRNG). The rand() function in Perl uses a linear congruential generator or similar algorithm that produces deterministic sequences based on the seed value. If an attacker can determine or guess the seed (often based on process start time or other predictable values), they can reproduce the entire sequence of "random" numbers generated by the application.

The vulnerable code can be found at line 86 of the OAuth.pm module, where rand() is used as the default entropy source for cryptographic operations. According to MetaCPAN Security Guide, cryptographic applications should use /dev/urandom, Crypt::URandom, or similar cryptographically secure random sources.

Attack Vector

This vulnerability is exploitable over the network without requiring authentication or user interaction. An attacker can potentially:

  1. Observe OAuth requests from a target application to analyze nonce patterns
  2. Determine or brute-force the PRNG seed based on timing information or observed output
  3. Predict future nonces and tokens generated by the application
  4. Forge valid OAuth signatures or replay previous requests with predicted values

The attack requires understanding of the application's OAuth implementation and timing, but does not require direct access to the vulnerable system.

Detection Methods for CVE-2025-40905

Indicators of Compromise

  • Unexpected OAuth authentication successes from unknown sources
  • Multiple requests with identical or sequential nonce values
  • OAuth signature validation failures followed by successful forgeries
  • Anomalous patterns in OAuth request timing correlating with nonce reuse

Detection Strategies

  • Audit Perl applications for usage of WWW::OAuth module versions 1.000 or earlier
  • Implement monitoring for OAuth nonce reuse or predictable patterns in authentication logs
  • Review application dependencies using CPAN security advisories and vulnerability databases
  • Conduct code review to identify any direct usage of rand() in security-sensitive contexts

Monitoring Recommendations

  • Enable detailed logging of OAuth authentication events including nonces and timestamps
  • Set up alerts for repeated authentication attempts with similar nonce patterns
  • Monitor for unusual OAuth token usage patterns that may indicate prediction attacks
  • Track and baseline normal OAuth request volumes to detect anomalous activity

How to Mitigate CVE-2025-40905

Immediate Actions Required

  • Identify all applications using WWW::OAuth 1.000 or earlier in your environment
  • Evaluate the criticality of OAuth authentication in affected applications
  • Consider implementing additional authentication layers while awaiting a patched version
  • Review OAuth logs for any signs of exploitation or nonce prediction attempts

Patch Information

As of the last update on 2026-02-17, consult the MetaCPAN OAuth Module Source and the OpenWall OSS-Security Mailing List for the latest information on patches and updated module versions. Monitor CPAN for new releases of WWW::OAuth that address this cryptographic weakness.

Workarounds

  • Override the default random source in WWW::OAuth with a cryptographically secure alternative such as Crypt::URandom
  • Implement application-level nonce tracking to detect and reject reused or predictable values
  • Add rate limiting and anomaly detection for OAuth authentication endpoints
  • Consider migrating to OAuth 2.0 implementations that use more secure token generation methods

The recommended approach for Perl applications requiring cryptographic randomness is to use modules like Crypt::URandom or read directly from /dev/urandom on Unix-like systems. Refer to the MetaCPAN Security Guide and Perl Documentation: rand Function for guidance on proper random number generation for security purposes.

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

  • Vulnerability Details
  • TypeInformation Disclosure

  • Vendor/TechPerl

  • SeverityHIGH

  • CVSS Score7.3

  • EPSS Probability0.05%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:L
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityNone
  • AvailabilityLow
  • CWE References
  • CWE-338
  • Technical References
  • MetaCPAN OAuth Module Source

  • Perl Documentation: rand Function

  • MetaCPAN Security Guide: Random Data

  • OpenWall OSS-Security Mailing List
  • Related CVEs
  • CVE-2023-31486: HTTP::Tiny Information Disclosure Flaw

  • CVE-2025-40928: JSON::XS Perl DoS Vulnerability

  • CVE-2026-40199: Net::CIDR::Lite Auth Bypass Vulnerability

  • CVE-2026-40198: Net::CIDR::Lite Auth Bypass Vulnerability
Default Legacy - Prefooter | Experience the World’s Most Advanced Cybersecurity Platform

Experience the World’s Most Advanced Cybersecurity Platform

See how our intelligent, autonomous cybersecurity platform can protect your organization now and into the future.

Try SentinelOne
  • Get Started
  • Get a Demo
  • Product Tour
  • Why SentinelOne
  • Pricing & Packaging
  • FAQ
  • Contact
  • Contact Us
  • Customer Support
  • SentinelOne Status
  • Language
  • Platform
  • Singularity Platform
  • Singularity Endpoint
  • Singularity Cloud
  • Singularity AI-SIEM
  • Singularity Identity
  • Singularity Marketplace
  • Purple AI
  • Services
  • Wayfinder TDR
  • SentinelOne GO
  • Technical Account Management
  • Support Services
  • Verticals
  • Energy
  • Federal Government
  • Finance
  • Healthcare
  • Higher Education
  • K-12 Education
  • Manufacturing
  • Retail
  • State and Local Government
  • Cybersecurity for SMB
  • Resources
  • Blog
  • Labs
  • Case Studies
  • Videos
  • Product Tours
  • Events
  • Cybersecurity 101
  • eBooks
  • Webinars
  • Whitepapers
  • Press
  • News
  • Ransomware Anthology
  • Company
  • About Us
  • Our Customers
  • Careers
  • Partners
  • Legal & Compliance
  • Security & Compliance
  • Investor Relations
  • S Foundation
  • S Ventures

©2026 SentinelOne, All Rights Reserved.

Privacy Notice Terms of Use

English