The SentinelOne Annual Threat Report - A Defenders Guide from the FrontlinesThe SentinelOne Annual Threat ReportGet the Report
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-2022-32224

CVE-2022-32224: Active Record YAML Serialization RCE Flaw

CVE-2022-32224 is a remote code execution vulnerability in Active Record's YAML serialized columns that allows attackers with database access to execute arbitrary code. This article covers technical details, affected versions, and mitigation.

Published: February 18, 2026

CVE-2022-32224 Overview

A critical insecure deserialization vulnerability exists in Ruby on Rails Active Record when using YAML serialized columns. This vulnerability allows an attacker who can manipulate data in the database (through means such as SQL injection) to escalate their attack to achieve Remote Code Execution (RCE). The vulnerability affects multiple versions of Active Record, making it a significant security concern for Ruby on Rails applications that utilize YAML serialization for database columns.

Critical Impact

Attackers with database access can escalate to full Remote Code Execution by exploiting unsafe YAML deserialization in Active Record serialized columns.

Affected Products

  • Active Record versions prior to 7.0.3.1
  • Active Record versions prior to 6.1.6.1
  • Active Record versions prior to 6.0.5.1
  • Active Record versions prior to 5.2.8.1

Discovery Timeline

  • 2022-12-05 - CVE-2022-32224 published to NVD
  • 2025-04-24 - Last updated in NVD database

Technical Details for CVE-2022-32224

Vulnerability Analysis

This vulnerability stems from unsafe YAML deserialization in Active Record's serialized column functionality. When Active Record deserializes YAML data from database columns, it can instantiate arbitrary Ruby objects, which can lead to code execution if an attacker can control the serialized data.

The attack requires the adversary to first gain the ability to write arbitrary data to the database. This is commonly achieved through SQL injection vulnerabilities or compromised database credentials. Once the attacker can modify the serialized YAML content stored in database columns, they can craft malicious YAML payloads that, when deserialized by Active Record, execute arbitrary code on the server.

This represents a classic insecure deserialization pattern (CWE-502) where untrusted data is processed by a serialization framework without proper validation. The network-accessible nature of web applications combined with the potential for SQL injection makes this a particularly dangerous vulnerability.

Root Cause

The root cause is the unsafe deserialization of YAML content stored in Active Record serialized columns. YAML in Ruby supports object instantiation during parsing, which means specially crafted YAML payloads can trigger arbitrary code execution when deserialized. Prior to the patched versions, Active Record did not restrict the types of objects that could be instantiated during YAML deserialization, allowing attackers to leverage this capability for RCE.

Attack Vector

The attack vector is network-based and requires the attacker to first compromise the database or have the ability to inject malicious data into serialized columns. The typical attack chain involves:

  1. Exploiting a SQL injection vulnerability or obtaining database access through other means
  2. Inserting malicious YAML payload into a serialized column
  3. Triggering the application to read and deserialize the compromised data
  4. Achieving code execution when the malicious YAML payload is processed

The vulnerability mechanism involves crafting YAML that includes embedded Ruby objects with dangerous initialization or callback methods. When Active Record deserializes this YAML, the malicious objects are instantiated and their code is executed in the context of the Rails application. For detailed technical analysis, refer to the Ruby on Rails Security Discussion.

Detection Methods for CVE-2022-32224

Indicators of Compromise

  • Unusual or malformed YAML content in database columns that contain serialized data
  • Database queries attempting to modify serialized columns with unexpected payloads
  • Application errors related to YAML parsing or unexpected object instantiation
  • Signs of SQL injection attempts targeting tables with serialized columns

Detection Strategies

  • Monitor application logs for YAML deserialization errors or unexpected class instantiation
  • Implement database activity monitoring to detect suspicious modifications to serialized columns
  • Deploy Web Application Firewalls (WAF) configured to detect SQL injection patterns
  • Use runtime application self-protection (RASP) solutions to monitor deserialization operations

Monitoring Recommendations

  • Enable verbose logging for Active Record operations involving serialized attributes
  • Implement integrity monitoring for critical database tables containing serialized data
  • Set up alerts for failed deserialization attempts or unexpected object types during YAML processing
  • Monitor for SQL injection attack patterns in application and web server logs

How to Mitigate CVE-2022-32224

Immediate Actions Required

  • Upgrade Active Record to a patched version: 7.0.3.1, 6.1.6.1, 6.0.5.1, or 5.2.8.1 or later
  • Audit your application for SQL injection vulnerabilities that could enable database manipulation
  • Review database access controls and ensure principle of least privilege
  • Consider migrating serialized columns from YAML to JSON format where possible

Patch Information

The vulnerability has been addressed in Active Record versions 7.0.3.1, 6.1.6.1, 6.0.5.1, and 5.2.8.1. The patched versions introduce safer YAML deserialization that restricts the types of objects that can be instantiated. Organizations should update to these versions or later as soon as possible.

For detailed patch information and security advisories, refer to:

  • GitHub Security Advisory GHSA-3hhc-qp5v-9p2j
  • Ruby on Rails Security Discussion

Workarounds

  • Migrate from YAML serialization to JSON serialization for database columns where feasible
  • Implement additional input validation and sanitization for any data paths leading to the database
  • Consider using the safe_load method for YAML parsing with explicit permitted classes
  • Deploy additional security layers such as database firewalls to restrict unauthorized data modifications
bash
# Update Gemfile to use patched Active Record version
# For Rails 7.x:
bundle update activerecord --conservative
# Verify installed version
bundle exec gem list activerecord
# Expected output should show version >= 7.0.3.1 (or corresponding patched version for your Rails series)

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

  • Vulnerability Details
  • TypeRCE

  • Vendor/TechActiverecord

  • SeverityCRITICAL

  • CVSS Score9.8

  • EPSS Probability1.93%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityNone
  • AvailabilityHigh
  • CWE References
  • CWE-502
  • Technical References
  • Ruby on Rails Security Discussion
  • Vendor Resources
  • GitHub Security Advisory
  • Latest CVEs
  • CVE-2025-52479: HTTP.jl & URIs.jl CRLF Injection Flaw

  • CVE-2026-31740: Linux Kernel Race Condition Vulnerability

  • CVE-2026-31743: Linux Kernel Buffer Overflow Vulnerability

  • CVE-2026-31744: Linux Kernel NULL Pointer 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