---
title: "CVE-2026-41316\n    | Ubuntu"
description: Ubuntu is an open source software operating system that runs from the
  desktop, to the cloud, to all your internet connected things.
url: https://ubuntu.com/security/CVE-2026-41316?format=md
keywords: index, follow
---

# CVE-2026-41316

Publication date 24 April 2026

Last updated 14 May 2026

---

Ubuntu priority

**Medium**

[Why this priority?](https://ubuntu.com/security/cves/about#priority )

## Cvss 3 Severity Score

**8.1 · High**

[Score breakdown](https://ubuntu.com/security/CVE-2026-41316?format=md#impact-score)

Toggle side navigation

## Description

ERB is a templating system for Ruby. Ruby 2.7.0 (before ERB 2.2.0 was
published on rubygems.org) introduced an `@\_init` instance variable guard
in `ERB#result` and `ERB#run` to prevent code execution when an ERB object
is reconstructed via `Marshal.load` (deserialization). However, three other
public methods that also evaluate `@src` via `eval()` were not given the
same guard: `ERB#def\_method`, `ERB#def\_module`, and `ERB#def\_class`. An
attacker who can trigger `Marshal.load` on untrusted data in a Ruby
application that has `erb` loaded can use `ERB#def\_module` (zero-arg,
default parameters) as a code execution sink, bypassing the `@\_init`
protection entirely. ERB 4.0.3.1, 4.0.4.1, 6.0.1.1, and 6.0.4 patch the
issue.

## Status

Show unmaintained releases

| Package | Ubuntu Release | Status |
| --- | --- | --- |
| ruby3.3 | 26.04 LTS resolute | Needs evaluation |
| 25.10 questing | Ignored end of life, was needs-triage |
| 24.04 LTS noble | Not in release |
| 22.04 LTS jammy | Not in release |
| jruby | 26.04 LTS resolute | Needs evaluation |
| 25.10 questing | Ignored end of life, was needs-triage |
| 24.04 LTS noble | Needs evaluation |
| 22.04 LTS jammy | Not in release |
| 20.04 LTS focal | Needs evaluation |
| 18.04 LTS bionic | Needs evaluation |
| 16.04 LTS xenial | Needs evaluation |
| 14.04 LTS trusty | Needs evaluation |
| ruby2.3 | 26.04 LTS resolute | Not in release |
| 25.10 questing | Not in release |
| 24.04 LTS noble | Not in release |
| 22.04 LTS jammy | Not in release |
| 16.04 LTS xenial | Needs evaluation |
| ruby2.5 | 26.04 LTS resolute | Not in release |
| 25.10 questing | Not in release |
| 24.04 LTS noble | Not in release |
| 22.04 LTS jammy | Not in release |
| 18.04 LTS bionic | Needs evaluation |
| ruby2.7 | 26.04 LTS resolute | Not in release |
| 25.10 questing | Not in release |
| 24.04 LTS noble | Not in release |
| 22.04 LTS jammy | Not in release |
| 20.04 LTS focal | Needs evaluation |
| ruby3.0 | 26.04 LTS resolute | Not in release |
| 25.10 questing | Not in release |
| 24.04 LTS noble | Not in release |
| 22.04 LTS jammy | Needs evaluation |
| ruby3.2 | 26.04 LTS resolute | Not in release |
| 25.10 questing | Not in release |
| 24.04 LTS noble | Needs evaluation |
| 22.04 LTS jammy | Not in release |

---

* [How can I get the fixes?](https://ubuntu.com/security/cves/about#security)
* [What do statuses mean?](https://ubuntu.com/security/cves/about#statuses)

## Severity score breakdown

CVSS version:
CVSS v3.0

**Base score**

8.1 · High

* Base metrics

  | Parameter | Value |
  | --- | --- |
  | Attack vector | Network |
  | Attack complexity | High |
  | Privileges required | None |
  | User interaction | None |
  | Scope | Unchanged |
  | Confidentiality impact | High |
  | Integrity impact | High |
  | Availability impact | High |
* Scores

  | Parameter | Value |
  | --- | --- |
  | Base score | 8.1 · High |
  | Exploitability score | - |
  | Impact score | - |

**Vector:** CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H

## References

* [MITRE](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2026-41316)
* [NVD](https://nvd.nist.gov/vuln/detail/CVE-2026-41316)
* [Launchpad](https://launchpad.net/bugs/cve/CVE-2026-41316)
* [Debian](https://security-tracker.debian.org/tracker/CVE-2026-41316)

### Other references

* <https://www.cve.org/CVERecord?id=CVE-2026-41316>
* <https://github.com/ruby/erb/security/advisories/GHSA-q339-8rmv-2mhv>
