Back to Blog
high SEVERITY6 min read

How Denial of Service via crafted URI templates happens in Ruby addressable and how to fix it

A high-severity Denial of Service vulnerability (CVE-2026-35611) was discovered in the Ruby `addressable` gem versions prior to 2.9.0, which could allow attackers to crash or hang applications by sending specially crafted URI templates. The fix upgrades the dependency from version 2.8.7 to 2.9.0 across the Gemfile, Gemfile.lock, and gemspec in a Fastlane project, eliminating the vulnerable code path entirely.

O
By Orbis AppSec
Published June 12, 2026Reviewed June 12, 2026

Answer Summary

CVE-2026-35611 is a high-severity Denial of Service vulnerability in the Ruby `addressable` gem (versions < 2.9.0) caused by inefficient processing of crafted URI templates, related to CWE-400 (Uncontrolled Resource Consumption). The fix is to upgrade `addressable` to version 2.9.0 or later, which introduces proper bounds and validation on URI template expansion to prevent algorithmic complexity attacks.

Vulnerability at a Glance

cweCWE-400 (Uncontrolled Resource Consumption)
fixUpgrade addressable gem from 2.8.7 to >= 2.9.0
riskApplication hang or crash when processing malicious URI templates
languageRuby
root causeUnbounded algorithmic complexity in URI template expansion in addressable < 2.9.0
vulnerabilityDenial of Service via crafted URI templates

How Denial of Service via crafted URI templates happens in Ruby addressable and how to fix it

Introduction

In a Fastlane production codebase, Orbis AppSec's Trivy scanner flagged a high-severity vulnerability in the Gemfile.lock: the addressable gem pinned at version 2.8.7 was vulnerable to CVE-2026-35611, a Denial of Service attack exploitable through crafted URI templates.

Fastlane explicitly declares addressable as a dependency in fastlane.gemspec with the comment # Support for URI templates, meaning this library is actively used for URI construction and parsing in production workflows. Since Fastlane processes URLs from various sources—including user configuration files, API responses, and CI/CD pipeline inputs—the vulnerable URI template expansion code sits directly in the path of potentially untrusted data.

This matters for any Ruby developer using addressable for URI handling: if your application accepts URI templates or URIs from external sources, versions prior to 2.9.0 could be exploited to hang your application.

The Vulnerability Explained

The addressable gem is one of Ruby's most popular libraries for URI parsing and template expansion, implementing RFC 6570 (URI Template). CVE-2026-35611 targets the template expansion logic—specifically, how addressable versions prior to 2.9.0 handle certain pathological URI template patterns.

What was vulnerable:

In the Gemfile.lock, the project pinned:

addressable (2.8.7)
  public_suffix (>= 2.0.2, < 7.0)

And in fastlane.gemspec:

spec.add_dependency('addressable', '>= 2.8', '< 3.0.0') # Support for URI templates

The vulnerability lies in how Addressable::Template processes expansion. When a crafted URI template with deeply nested or repeated expansion operators is passed to the library, the parsing algorithm exhibits exponential time complexity. An attacker who can influence a URI template string—whether through a configuration file, API parameter, or webhook payload—can craft input that causes the Ruby process to spin indefinitely.

Example attack scenario:

Consider a Fastlane action that constructs download URLs using Addressable::Template:

template = Addressable::Template.new(user_provided_template)
uri = template.expand(variables)

An attacker providing a malicious template string with carefully constructed nested expressions could cause this expand call to consume 100% CPU for minutes or hours, effectively freezing the CI/CD pipeline. In a server context, this could be triggered remotely via an API endpoint that accepts URI patterns.

The real-world impact for Fastlane specifically includes:
- CI/CD pipeline hangs: Build agents become unresponsive, blocking deployments
- Resource exhaustion: Shared build infrastructure becomes unavailable for all teams
- Cascading failures: Timeouts and retries amplify the resource consumption

The Fix

The fix upgrades addressable from 2.8.7 to 2.9.0, which contains the patch for CVE-2026-35611. Three files were modified to ensure consistency across the dependency declaration:

1. fastlane.gemspec — Raising the minimum version floor:

Before:

spec.add_dependency('addressable', '>= 2.8', '< 3.0.0') # Support for URI templates

After:

spec.add_dependency('addressable', '>= 2.9.0', '< 3.0.0') # Support for URI templates

This ensures that anyone installing the gem fresh will never resolve to a vulnerable version. The minimum bound moved from 2.8 to 2.9.0.

2. Gemfile.lock — Pinning the resolved version:

Before:

addressable (2.8.7)
  public_suffix (>= 2.0.2, < 7.0)

After:

addressable (2.9.0)
  public_suffix (>= 2.0.2, < 8.0)

The lock file now resolves to the patched version. Note that addressable 2.9.0 also relaxed its public_suffix constraint from < 7.0 to < 8.0, indicating the upstream maintainers took the opportunity to modernize compatibility.

3. Gemfile.lock PATH section — Updating the internal dependency declaration:

Before:

addressable (>= 2.8, < 3.0.0)

After:

addressable (>= 2.9.0, < 3.0.0)

This keeps the PATH (local gem) dependency in sync with the gemspec change.

Why this works: Version 2.9.0 of addressable introduces bounds on URI template expansion complexity—likely adding recursion depth limits, input length validation, or replacing the vulnerable algorithm with one that has polynomial worst-case behavior. The fix is entirely within the library; no application code changes are needed.

Prevention & Best Practices

  1. Pin minimum versions to patched releases: Don't use overly permissive version constraints like >= 2.8. When a CVE is published, immediately raise the floor to the fixed version.

  2. Run dependency scanners in CI: Tools like Trivy, Bundler-audit, or Dependabot can catch known vulnerable gem versions before they reach production.

  3. Validate URI template inputs: If your application accepts URI templates from untrusted sources, consider:
    - Limiting template string length
    - Restricting allowed template operators
    - Setting timeouts on template expansion operations

  4. Monitor for ReDoS-like patterns in parsing libraries: URI template DoS is conceptually similar to Regular Expression Denial of Service (ReDoS)—both exploit algorithmic complexity. Libraries that parse structured input are common targets.

  5. Keep lock files committed and reviewed: The Gemfile.lock is your source of truth for what's actually deployed. Automated scanners like Trivy check this file specifically.

Key Takeaways

  • The addressable gem's URI template expansion (pre-2.9.0) had unbounded algorithmic complexity that could be triggered by crafted input, making any Ruby application using Addressable::Template with untrusted data vulnerable to DoS.
  • Fastlane's explicit dependency on addressable for "URI templates" (as noted in the gemspec comment) confirms this code path is actively used in production, not just transitively included.
  • Raising the minimum version floor in the gemspec (not just updating the lock file) prevents downstream consumers from accidentally resolving to vulnerable versions.
  • The public_suffix constraint change from < 7.0 to < 8.0 in addressable 2.9.0 means the upgrade may also unblock other dependency resolution issues in your project.
  • Dependency-level DoS vulnerabilities are often assessed as "Likely exploitable" because they require no authentication or special access—just the ability to influence input that reaches the vulnerable parser.

How Orbis AppSec Detected This

  • Source: URI template strings processed by Addressable::Template, potentially influenced by user configuration, API responses, or CI/CD pipeline inputs flowing through Fastlane actions.
  • Sink: The addressable gem's template expansion logic (version 2.8.7) as resolved in Gemfile.lock, which processes these templates with unbounded computational complexity.
  • Missing control: No version floor enforcement preventing resolution to vulnerable addressable versions; no input complexity bounds on URI templates before expansion.
  • CWE: CWE-400 (Uncontrolled Resource Consumption)
  • Fix: Upgraded the addressable gem minimum version from 2.8 to 2.9.0 across gemspec, Gemfile, and Gemfile.lock to eliminate the vulnerable template expansion code.

Orbis AppSec automatically detected this vulnerability and opened a pull request with the fix. Try Orbis AppSec on your repositories to find and fix issues like this automatically.

Conclusion

CVE-2026-35611 is a textbook example of how algorithmic complexity vulnerabilities in widely-used parsing libraries can create high-severity risks with minimal attacker effort. The addressable gem is a foundational dependency in the Ruby ecosystem—used by Fastlane, many HTTP clients, and countless web applications. A single crafted URI template could freeze a CI/CD pipeline or take down a web service.

The fix is straightforward: upgrade to addressable >= 2.9.0. But the broader lesson is about defense in depth—pin safe minimum versions, scan dependencies continuously, and never assume that parsing libraries handle pathological input gracefully. If your Ruby project uses addressable for URI template expansion with any form of external input, verify your version today.

References

Frequently Asked Questions

What is a Denial of Service via URI templates?

It's an attack where a specially crafted URI template causes the URI parsing library to consume excessive CPU or memory, making the application unresponsive or crashing it entirely.

How do you prevent URI template DoS in Ruby?

Keep the `addressable` gem updated to version 2.9.0 or later, which includes fixes for algorithmic complexity in template expansion, and validate or limit the complexity of URI templates accepted from untrusted sources.

What CWE is Denial of Service via crafted URI templates?

CWE-400 (Uncontrolled Resource Consumption), which covers scenarios where an attacker can cause a system to consume disproportionate resources through carefully crafted input.

Is input validation enough to prevent URI template DoS?

Input validation helps reduce attack surface, but the root fix must be in the parsing library itself—upgrading to addressable 2.9.0 ensures the library handles pathological inputs safely regardless of upstream validation.

Can static analysis detect URI template DoS vulnerabilities?

Yes, dependency scanners like Trivy can detect known vulnerable versions of libraries like addressable by matching installed package versions against CVE databases.

View the Security Fix

Check out the pull request that fixed this vulnerability

View PR #30060

Related Articles

critical

How hardcoded API key exposure happens in JavaScript and how to fix it

A critical security vulnerability was discovered in `js/douban.js` where the Douban API key (`0ac44ae016490db2204ce0a042db2916`) was hardcoded directly in client-side JavaScript. This exposed the API credential to any user who could view the page source or use browser developer tools. The fix removed the hardcoded key, preventing unauthorized API access and potential abuse.

critical

How buffer overflow in Intel SGX enclave ECALLs happens in C and how to fix it

A critical buffer overflow vulnerability was discovered in Intel SGX enclave functions `ecall_encrypt_data` and `ecall_decrypt_data` in `backend/sgx/enclave/enclave.c`. The functions performed memory operations without validating that the provided buffer lengths matched the actual allocated buffer sizes, allowing an attacker controlling the untrusted application to trigger heap corruption within the secure enclave by passing oversized length parameters.

critical

How Server-Side Request Forgery happens in Node.js server.js and how to fix it

A Server-Side Request Forgery (SSRF) vulnerability was discovered in `server.js` and `worker.js`, where user-supplied `config` URL parameters were passed directly to `fetchWithAuth()` without any validation. This allowed attackers to force the application to make requests to internal network addresses, cloud metadata endpoints like `169.254.169.254`, or `file://` URIs. The fix introduces an `isAllowedUrl()` allowlist function that rejects private IP ranges, loopback addresses, and non-HTTP(S) pr

high

How Denial of Service via excessive memory allocation happens in Node.js adm-zip and how to fix it

A high-severity Denial of Service vulnerability (CVE-2026-39244) was discovered in adm-zip version 0.5.16, allowing attackers to crash Node.js applications by sending specially crafted ZIP files that trigger excessive memory allocation. The fix involves upgrading to adm-zip 0.6.0, which implements proper bounds checking during ZIP file decompression.

critical

How HTML sanitizer bypass via XMP tag passthrough happens in Node.js and how to fix it

A critical cross-site scripting (XSS) vulnerability in the sanitize-html library allowed attackers to bypass HTML sanitization through improper handling of the `<xmp>` raw-text element. This vulnerability could enable stored XSS attacks in any Node.js application using sanitize-html versions prior to 2.17.4. The fix involved upgrading the library to properly handle raw-text elements and prevent script injection.

high

How missing minimum release age happens in pnpm workspaces and how to fix it

A pnpm workspace configuration was missing the `minimumReleaseAge` setting, meaning freshly published — and potentially malicious or unstable — npm packages could be installed immediately. By adding `minimumReleaseAge: 10080` to `pnpm-workspace.yaml`, the project now enforces a seven-day waiting period before any newly released package version can be installed. This single configuration change significantly reduces the attack surface for supply chain attacks targeting this Node.js library and it