<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Rubygems — CraftedSignal Threat Feed</title><link>https://feed.craftedsignal.io/vendors/rubygems/</link><description>Trending threats, MITRE ATT&amp;CK coverage, and detection metadata — refreshed continuously.</description><generator>Hugo</generator><language>en</language><managingEditor>hello@craftedsignal.io</managingEditor><webMaster>hello@craftedsignal.io</webMaster><lastBuildDate>Sat, 25 Apr 2026 12:00:00 +0000</lastBuildDate><atom:link href="https://feed.craftedsignal.io/vendors/rubygems/feed.xml" rel="self" type="application/rss+xml"/><item><title>ERB Deserialization Bypass via def_module/def_method/def_class</title><link>https://feed.craftedsignal.io/briefs/2026-04-erb-deserialization/</link><pubDate>Sat, 25 Apr 2026 12:00:00 +0000</pubDate><author>hello@craftedsignal.io</author><guid isPermaLink="true">https://feed.craftedsignal.io/briefs/2026-04-erb-deserialization/</guid><description>A deserialization vulnerability exists in Ruby ERB versions before 4.0.3.1, version 4.0.4, ERB versions 5.0.0 before 6.0.1.1, and ERB versions 6.0.2 before 6.0.4. The `@_init` instance variable guard in `ERB#result` and `ERB#run` can be bypassed via `ERB#def_module`, `ERB#def_method`, and `ERB#def_class`, allowing arbitrary code execution when an ERB object is reconstructed via `Marshal.load` on untrusted data.</description><content:encoded><![CDATA[<p>Ruby versions before ERB 2.2.0 implemented an <code>@_init</code> instance variable guard in <code>ERB#result</code> and <code>ERB#run</code> to prevent code execution upon deserialization via <code>Marshal.load</code>. This guard is intended to block execution when an ERB object is reconstructed from untrusted data. However, the methods <code>ERB#def_method</code>, <code>ERB#def_module</code>, and <code>ERB#def_class</code> were not given the same protection, creating a bypass. An attacker capable of triggering <code>Marshal.load</code> on untrusted data in a Ruby application with the <code>erb</code> gem loaded can exploit <code>ERB#def_module</code> (using its zero-argument, default-parameter form) as a code execution sink. This bypass impacts Ruby on Rails applications that import untrusted serialized data, Ruby tools employing <code>Marshal.load</code> for caching or IPC, and legacy Rails applications (pre-7.0) utilizing Marshal for cookie session serialization. This bypass renders the <code>@_init</code> mitigation ineffective across all ERB versions from 2.2.0 through 6.0.3. Combined with the DeprecatedInstanceVariableProxy gadget (present in all ActiveSupport versions through 7.2.3), this enables a universal RCE gadget chain for Ruby 3.2+ applications using Rails. The vulnerability is identified as CVE-2026-41316.</p>
<h2 id="attack-chain">Attack Chain</h2>
<ol>
<li>The attacker crafts a malicious Ruby object containing an <code>ERB</code> instance and/or an <code>ActiveSupport::Deprecation::DeprecatedInstanceVariableProxy</code> instance.</li>
<li>The <code>ERB</code> instance has its <code>@src</code> instance variable set to a string containing malicious code with the &ldquo;end\nsystem(&lsquo;id&rsquo;)\ndef x&rdquo; payload.</li>
<li>The vulnerable application calls <code>Marshal.load</code> on the crafted object, triggering deserialization.</li>
<li>During deserialization, the <code>DeprecatedInstanceVariableProxy</code> is instantiated (if used), which then invokes the <code>ERB#def_module</code> method via <code>method_missing</code>.</li>
<li>The <code>ERB#def_module</code> method calls <code>ERB#def_method</code> without checking the <code>@_init</code> guard.</li>
<li>Inside <code>ERB#def_method</code>, the malicious code in <code>@src</code> is wrapped in a method definition and evaluated via <code>module_eval</code>.</li>
<li>The &ldquo;end\nsystem(&lsquo;id&rsquo;)\ndef x&rdquo; payload causes the <code>system('id')</code> command to execute during the <code>module_eval</code> call, bypassing the intended deserialization protection.</li>
<li>The attacker achieves arbitrary code execution on the target system, gaining the ability to perform malicious actions.</li>
</ol>
<h2 id="impact">Impact</h2>
<p>Successful exploitation allows an attacker to execute arbitrary code on the target system. This affects Ruby applications, including Ruby on Rails, which use <code>Marshal.load</code> on untrusted data. Specific impact includes potential compromise of web servers and the ability to read sensitive files, modify data, or install malware. Vulnerable applications include those using <code>Marshal.load</code> for caching, data import, or IPC, and legacy Rails applications (pre-7.0) using Marshal for cookie session serialization. This bypass renders the @_init mitigation ineffective across all ERB versions from 2.2.0 through 6.0.3.</p>
<h2 id="recommendation">Recommendation</h2>
<ul>
<li>Upgrade your erb gem to version 4.0.3.1, 4.0.4.1, 6.0.1.1, or 6.0.4 to patch the vulnerability as described in the &ldquo;Patches&rdquo; section.</li>
<li>Avoid using <code>Marshal.load</code> on untrusted data, as it is inherently unsafe. Consider using alternative serialization formats like JSON or YAML.</li>
<li>Deploy the &ldquo;Detect ERB def_module Code Execution via Deserialization&rdquo; Sigma rule to detect exploitation attempts.</li>
</ul>
]]></content:encoded><category domain="severity">critical</category><category domain="type">advisory</category><category>deserialization</category><category>rce</category><category>ruby</category><category>rails</category></item><item><title>OpenC3 COSMOS SQL Injection Vulnerability in QuestDB Time-Series Database</title><link>https://feed.craftedsignal.io/briefs/2024-01-09-openc3-sql-injection/</link><pubDate>Thu, 23 Apr 2026 14:12:02 +0000</pubDate><author>hello@craftedsignal.io</author><guid isPermaLink="true">https://feed.craftedsignal.io/briefs/2024-01-09-openc3-sql-injection/</guid><description>A SQL injection vulnerability exists in the Time-Series Database (TSDB) component of COSMOS, allowing an authenticated remote user to execute arbitrary SQL commands, including telemetry data disclosure and deletion.</description><content:encoded><![CDATA[<p>A SQL injection vulnerability has been identified in the OpenC3 COSMOS Time-Series Database (TSDB) component, which utilizes QuestDB. The vulnerability resides within the <code>tsdb_lookup</code> function in the <code>cvt_model.rb</code> file, where user-supplied input is directly incorporated into SQL queries without proper sanitization. An authenticated attacker with &ldquo;tlm&rdquo; permissions, which includes Admin, Operator, Viewer, or Runner roles, can exploit this flaw to inject arbitrary SQL commands. This can lead to unauthorized data access, modification, or deletion within the TSDB. The affected versions are OpenC3 rubygems package versions &gt;= 6.7.0 and &lt; 7.0.0-rc3. Successful exploitation allows attackers to compromise the confidentiality, integrity, and availability of telemetry data stored within the COSMOS system.</p>
<h2 id="attack-chain">Attack Chain</h2>
<ol>
<li>An attacker authenticates to the COSMOS system with a role that possesses &ldquo;tlm&rdquo; permissions (Admin, Operator, Viewer, or Runner).</li>
<li>The attacker crafts a malicious JSON-RPC request targeting the <code>get_tlm_values</code> endpoint.</li>
<li>Within the request body, the attacker injects a SQL payload into the <code>start_time</code> parameter, such as <code>' OR 1=1 --</code>.</li>
<li>The <code>tsdb_lookup</code> function incorporates the unsanitized input into a SQL query.</li>
<li>The injected SQL payload manipulates the query logic, allowing the attacker to bypass intended restrictions.</li>
<li>The attacker can then exfiltrate all telemetry data within the database by manipulating the SQL query.</li>
<li>The attacker modifies the SQL payload to execute arbitrary commands, such as <code>DROP TABLE</code> statements.</li>
<li>The attacker successfully deletes historical data from the database, impacting data availability and system integrity.</li>
</ol>
<h2 id="impact">Impact</h2>
<p>Successful exploitation of this SQL injection vulnerability allows an attacker to perform unauthorized actions on the OpenC3 COSMOS Time-Series Database (TSDB). An attacker with &ldquo;tlm&rdquo; permissions can disclose sensitive telemetry data, modify existing data, or delete data altogether. The vulnerability impacts systems running OpenC3 rubygems package versions &gt;= 6.7.0 and &lt; 7.0.0-rc3. Depending on the role of the compromised account and the specific SQL commands executed, an attacker could potentially cause significant disruption to operations relying on the integrity and availability of telemetry data.</p>
<h2 id="recommendation">Recommendation</h2>
<ul>
<li>Upgrade the <code>rubygems/openc3</code> package to version 7.0.0-rc3 or later to remediate the SQL injection vulnerability.</li>
<li>Implement input sanitization on user-supplied data within the <code>tsdb_lookup</code> function in <code>cvt_model.rb</code> to prevent SQL injection attacks.</li>
<li>Deploy the Sigma rule &ldquo;Detect Suspicious OpenC3 Telemetry Requests&rdquo; to identify potential exploitation attempts targeting the <code>get_tlm_values</code> endpoint.</li>
<li>Review and restrict &ldquo;tlm&rdquo; permissions to the <code>get_tlm_values</code> RPC endpoint according to the principle of least privilege, limiting access to only those users who require it.</li>
</ul>
]]></content:encoded><category domain="severity">critical</category><category domain="type">advisory</category><category>sql-injection</category><category>openc3</category><category>cosmos</category><category>questdb</category><category>telemetry</category></item><item><title>OpenC3 COSMOS Script Runner Permissions Bypass</title><link>https://feed.craftedsignal.io/briefs/2024-11-openc3-cosmos-bypass/</link><pubDate>Fri, 08 Nov 2024 12:00:00 +0000</pubDate><author>hello@craftedsignal.io</author><guid isPermaLink="true">https://feed.craftedsignal.io/briefs/2024-11-openc3-cosmos-bypass/</guid><description>The OpenC3 COSMOS Script Runner widget allows authenticated users to bypass API permissions checks and execute administrative actions by running specially crafted Python and Ruby scripts, leading to data manipulation and privilege escalation.</description><content:encoded><![CDATA[<p>The openc3-COSMOS-script-runner-api container includes a Script Runner widget that enables users to execute Python and Ruby scripts. A vulnerability exists where users with script execution privileges can bypass API permission checks due to shared networking among Docker containers. This bypass allows unauthorized administrative actions such as reading and modifying data within the Redis database, which can lead to the exposure of sensitive credentials and alteration of COSMOS settings. Attackers can also read and write to the buckets service, affecting configuration, logs, and plugins. The vulnerability affects versions prior to 7.0.0-rc3 of the rubygems/openc3 package, posing a significant risk to data integrity and system security. Any authenticated user with script execution capabilities can exploit this flaw to connect to any service within the Docker network, escalating their privileges and gaining control over critical system components.</p>
<h2 id="attack-chain">Attack Chain</h2>
<ol>
<li>An attacker logs into the OpenC3 COSMOS platform with a valid, non-administrative user account that has access to the Script Runner widget.</li>
<li>The attacker crafts a Ruby script to extract Redis credentials (username, password, hostname, port) by querying the environment variables within the <code>openc3-COSMOS-script-runner-api</code> container using a command like <code>puts \</code>env | grep redis``.</li>
<li>The attacker executes the Ruby script within the Script Runner widget, successfully retrieving the Redis credentials, which are then displayed in the script&rsquo;s output.</li>
<li>The attacker crafts a Python script using the obtained Redis credentials to connect to the Redis database. The script is designed to create a new entry or modify an existing one. For example, <code>r.hset('openc3__settings_hacked','store_url',json.dumps(setting_data))</code></li>
<li>The attacker executes the Python script within the Script Runner widget, successfully adding or modifying data in the Redis database, bypassing normal permission controls.</li>
<li>The attacker leverages the ability to write to the buckets service to modify critical system configuration files, such as the plugin store URL, by uploading a malicious file via a Python or Ruby script.</li>
<li>The attacker verifies the changes by using <code>redis-cli</code> to confirm the new data was added to the Redis database, or by observing the altered behavior of the system due to the modified configuration files.</li>
<li>The attacker gains complete control over the OpenC3 COSMOS environment by exploiting modified settings, potentially leading to data exfiltration, service disruption, or further lateral movement within the network.</li>
</ol>
<h2 id="impact">Impact</h2>
<p>Successful exploitation of this vulnerability allows unauthorized data disclosure and manipulation within the OpenC3 COSMOS environment. An attacker can access sensitive information such as Redis credentials, modify system settings, and alter configuration files, leading to privilege escalation. The number of affected installations is currently unknown, but the vulnerability poses a significant risk to organizations using OpenC3 COSMOS, potentially resulting in complete system compromise and loss of data integrity. The vulnerability allows unauthorized access to data and functionality typically restricted to administrators, bypassing intended security controls.</p>
<h2 id="recommendation">Recommendation</h2>
<ul>
<li>Upgrade the <code>rubygems/openc3</code> package to version 7.0.0-rc3 or later to remediate the vulnerability (reference: rubygems/openc3 v7.0.0-rc3).</li>
<li>Implement network segmentation to isolate the <code>openc3-COSMOS-script-runner-api</code> container from other critical services like Redis, limiting the blast radius of potential attacks.</li>
<li>Deploy the Sigma rule to detect the execution of suspicious scripts within the Script Runner widget that attempt to access Redis or modify configuration files.</li>
<li>Monitor process creation events within the <code>openc3-COSMOS-script-runner-api</code> container for commands such as <code>env | grep redis</code> or any calls to <code>redis-cli</code> which is abnormal behavior, and create alerts (reference: process_creation log source).</li>
</ul>
]]></content:encoded><category domain="severity">critical</category><category domain="type">advisory</category><category>openc3</category><category>cosmos</category><category>script-runner</category><category>permissions-bypass</category><category>privilege-escalation</category></item><item><title>Avo Framework Broken Access Control Vulnerability</title><link>https://feed.craftedsignal.io/briefs/2024-01-03-avo-broken-access-control/</link><pubDate>Wed, 03 Jan 2024 12:00:00 +0000</pubDate><author>hello@craftedsignal.io</author><guid isPermaLink="true">https://feed.craftedsignal.io/briefs/2024-01-03-avo-broken-access-control/</guid><description>Avo framework version 3.x contains a critical Broken Access Control vulnerability in the ActionsController. Due to insecure action lookup logic, an authenticated user can execute any Action class on any resource, even if the action is not registered for that specific resource. This leads to Privilege Escalation and unauthorized data manipulation across the entire application. Version 3.31.2 remediates this issue.</description><content:encoded><![CDATA[<p>A critical broken access control vulnerability exists within the Avo framework, specifically affecting version 3.x. This vulnerability resides in the <code>ActionsController</code> and stems from an insecure action lookup mechanism. An authenticated user, regardless of their privilege level, can execute any Action class (descendants of <code>Avo::BaseAction</code>) on any resource within the application. This occurs because the system fails to validate whether the requested action is legitimately registered or permitted for the resource context specified in the request. The absence of this verification allows for the circumvention of intended resource-action mappings. Successful exploitation leads to privilege escalation, unauthorized data manipulation, and potential compromise of the application&rsquo;s integrity. It is recommended to upgrade to version 3.31.2 or later, which addresses this vulnerability.</p>
<h2 id="attack-chain">Attack Chain</h2>
<ol>
<li>An attacker authenticates to the Avo admin panel with low-level privileges.</li>
<li>The attacker identifies a sensitive action class, such as <code>Avo::Actions::ToggleAdmin</code>.</li>
<li>The attacker identifies a target record ID, such as a user ID they wish to manipulate.</li>
<li>The attacker crafts a POST request to a resource endpoint where the target action is NOT registered (e.g., <code>/admin/resources/posts/actions</code>).</li>
<li>The POST request includes a payload containing the <code>action_id</code> parameter set to the sensitive action class (<code>Avo::Actions::ToggleAdmin</code>).</li>
<li>The POST request also includes a <code>fields[avo_resource_ids]</code> parameter set to the target record ID.</li>
<li>Due to the insecure action lookup in <code>Avo::ActionsController</code>, the server executes the <code>ToggleAdmin</code> action on the specified user ID.</li>
<li>The attacker&rsquo;s privileges are escalated, or unauthorized data manipulation occurs due to the successful execution of the unintended action.</li>
</ol>
<h2 id="impact">Impact</h2>
<p>The exploitation of this broken access control vulnerability can have severe consequences. A successful attack can lead to privilege escalation, allowing attackers to gain administrative control over the application. Unauthorized operations can be performed, leading to data breaches or data manipulation. Sensitive actions designed for restricted resources can be triggered against any record ID, potentially compromising the integrity and confidentiality of data. The impact includes unauthorized deletion, archival, or updates to records, causing reputational damage and potential financial losses.</p>
<h2 id="recommendation">Recommendation</h2>
<ul>
<li>Upgrade to Avo version 3.31.2 or later, which contains the necessary fix to restrict action lookup to registered actions for the current resource context.</li>
<li>Deploy the Sigma rule <code>Detect Avo Unauthorized Action Execution</code> to monitor for attempts to execute actions on resources where they are not registered.</li>
<li>Review and audit existing Avo action registrations to ensure that actions are appropriately mapped to resources within the application.</li>
</ul>
]]></content:encoded><category domain="severity">high</category><category domain="type">advisory</category><category>broken-access-control</category><category>privilege-escalation</category><category>ruby</category></item></channel></rss>