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-46336

CVE-2025-46336: Rack::Session Auth Bypass Vulnerability

CVE-2025-46336 is an authentication bypass vulnerability in Rack::Session::Pool middleware that allows attackers to maintain session access after user logout. This article covers technical details, affected versions, and mitigation.

Updated: January 22, 2026

CVE-2025-46336 Overview

CVE-2025-46336 is a race condition vulnerability in Rack::Session, a session management implementation for Rack. The vulnerability affects versions starting from 2.0.0 to before 2.1.1 when using the Rack::Session::Pool middleware. An attacker who has acquired a valid session cookie can exploit a timing window during user logout to retain illicit access to the session even after the legitimate user has attempted to log out.

Critical Impact

Attackers with a valid session cookie can maintain unauthorized access to user sessions by exploiting a race condition during the logout process, undermining session termination security controls.

Affected Products

  • Rack::Session versions 2.0.0 to before 2.1.1
  • Applications using Rack::Session::Pool middleware
  • Ruby web applications built on the Rack framework

Discovery Timeline

  • 2025-05-08 - CVE CVE-2025-46336 published to NVD
  • 2025-05-12 - Last updated in NVD database

Technical Details for CVE-2025-46336

Vulnerability Analysis

This vulnerability is classified as CWE-362 (Race Condition), specifically a Time-of-Check Time-of-Use (TOCTOU) issue in the session management logic. The flaw exists in the Rack::Session::Pool middleware's write_session method, which fails to verify whether a session still exists before allowing writes to the session pool.

When a user initiates logout, the session should be destroyed and any subsequent session writes should fail. However, the vulnerable code allowed session data to be written to the pool without first checking if the session had been invalidated. This creates a race condition window where an attacker with a stolen session cookie can trigger a long-running request that writes session data after the legitimate user has logged out, effectively recreating the session and maintaining persistent access.

The attack requires network access and assumes the attacker has already obtained a valid session cookie through other means (such as session hijacking or cross-site scripting). While the prerequisites reduce the likelihood of exploitation, successful attacks can result in unauthorized access to user accounts and potential data exposure.

Root Cause

The root cause lies in the write_session method within lib/rack/session/pool.rb. The method performed session writes without first validating that the session still existed in the pool. This missing validation check allowed a race condition where concurrent requests could restore a session that had been destroyed during logout, bypassing the session termination security control.

Attack Vector

The attack requires the following conditions to be met:

  1. Session Cookie Acquisition: The attacker must first obtain a valid session cookie (through XSS, network interception, or other means)
  2. Timing Window: The attacker must initiate a long-running request using the stolen session cookie
  3. Concurrent Logout: While the attacker's request is processing, the legitimate user must log out
  4. Session Restoration: The attacker's long-running request completes and writes session data, recreating the destroyed session

The vulnerability is exploited through the network and requires low privileges (a valid session) but does not require user interaction from the victim beyond their normal logout action.

ruby
# Vulnerable code in lib/rack/session/pool.rb
# The write_session method did not verify session existence before writing
def write_session(req, session_id, new_session, options)
  @mutex.synchronize do
    # Missing: validation that session still exists
    @pool.store session_id.private_id, new_session
    session_id
  end
end

The security patch adds a critical validation check:

ruby
def write_session(req, session_id, new_session, options)
  @mutex.synchronize do
    return false unless get_session_with_fallback(session_id)
    @pool.store session_id.private_id, new_session
    session_id
  end
end

Source: GitHub Commit Reference

Detection Methods for CVE-2025-46336

Indicators of Compromise

  • Session activity from a user account after the legitimate user has logged out
  • Multiple concurrent requests to the same session ID with unusual timing patterns
  • Long-running requests that span user logout events
  • Session cookies being used from multiple IP addresses or user agents simultaneously

Detection Strategies

  • Monitor for session activity after logout events have been recorded for that session
  • Implement session activity logging that captures request duration and timing relative to logout events
  • Alert on sessions that show activity from multiple geographic locations or client fingerprints
  • Review application logs for long-duration requests that may be designed to exploit the race condition

Monitoring Recommendations

  • Enable detailed session lifecycle logging including creation, access, and destruction events
  • Implement real-time monitoring for concurrent session usage patterns
  • Configure alerts for session resurrection events (session activity after documented destruction)
  • Deploy application performance monitoring to identify unusually long-running requests

How to Mitigate CVE-2025-46336

Immediate Actions Required

  • Upgrade Rack::Session to version 2.1.1 or later immediately
  • Audit session management configurations to ensure Rack::Session::Pool is using the patched version
  • Review application logs for any evidence of session persistence after user logouts
  • Consider implementing additional session validation at the application layer as defense-in-depth

Patch Information

The vulnerability has been patched in Rack::Session version 2.1.1. The fix adds a validation check in the write_session method that verifies the session still exists before allowing any writes to the session pool. This prevents the race condition by ensuring destroyed sessions cannot be inadvertently recreated.

For detailed patch information, refer to the GitHub Security Advisory and the commit reference.

Workarounds

  • If immediate upgrade is not possible, consider switching to an alternative session storage backend (such as cookie-based sessions with encryption)
  • Implement application-layer session validation that checks session validity on each request
  • Reduce session timeout values to limit the window for exploitation
  • Deploy additional monitoring to detect and respond to suspicious session activity patterns
bash
# Update Rack::Session to the patched version
bundle update rack-session

# Or specify the minimum version in Gemfile
echo "gem 'rack-session', '>= 2.1.1'" >> Gemfile
bundle install

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

  • Vulnerability Details
  • TypeAuth Bypass

  • Vendor/TechRack

  • SeverityMEDIUM

  • CVSS Score4.2

  • EPSS Probability0.03%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:L/I:L/A:N
  • Impact Assessment
  • ConfidentialityHigh
  • IntegrityNone
  • AvailabilityNone
  • CWE References
  • CWE-362
  • Technical References
  • GitHub Commit Reference

  • GitHub Security Advisory

  • GitHub Security Advisory
  • Related CVEs
  • CVE-2026-39324: Rack::Session Auth Bypass Vulnerability

  • CVE-2026-34835: Rack Auth Bypass Vulnerability

  • CVE-2026-34786: Rack Web Interface Auth Bypass Vulnerability

  • CVE-2026-34827: Rack Multipart Parser DoS 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