Skip to content
Heist/ feed
Back to feed
MediumFix available

AdonisJS: Unencoded route parameters can produce open redirects

Type: advisorySources: OSV

Route parameters are inserted into generated URLs without URI encoding. When an application passes untrusted input to a route whose first path segment is dynamic, a value beginning with / can produce a scheme-relative URL. For example: ```ts router.get('/:page', handler).as('pages.show') response.redirect().toRoute('pages.show', { page: '/evil.example.com', }) ``` This generates the following redirect: ```http Location: //evil.example.com ``` Browsers interpret this value as an external URL and redirect the user to `https://evil.example.com`. ## Details The shared `createURL()` helper is used by route URL builders, including `Router.makeUrl()` and `Response.redirect().toRoute()`. Route parameter values were appended without encoding: ```ts if (isDefined) { uriSegments.push(`${value}${token.end}`) } ``` Wildcard parameters had the same behavior: ```ts uriSegments.push(`${values.join('/')}${token.end}`) ``` **The issue does not affect APIs that intentionally accept complete redirect URLs. Exploitation requires an application to pass attacker-controlled data as a route parameter and use the generated URL as a redirect destination.** ## Impact An attacker may craft a link on a trusted application domain that redirects a victim to an attacker-controlled website. This can facilitate phishing and may be chained with authentication or OAuth flows that rely on trusted redirect destinations. Applications are affected when they: - define a route whose first path segment is dynamic; and

Products
@adonisjs/http-server
Affected versions
Not specified
Fixed versions
8.2.3, 9.3.0
CVEs
CVE-2026-107718
Confirmed fixed CVEs
Not specified
Updated in this feed
28 Oct 2026, 10:07 UTC · Revision 1

Source evidence

AdonisJS: Unencoded route parameters can produce open redirects

core-osv · Original source

Published 8 Oct 2026, 22:09 UTC

Route parameters are inserted into generated URLs without URI encoding. When an application passes untrusted input to a route whose first path segment is dynamic, a value beginning with / can produce a scheme-relative URL. For example: ```ts router.get('/:page', handler).as('pages.show') response.redirect().toRoute('pages.show', { page: '/evil.example.com', }) ``` This generates the following redirect: ```http Location: //evil.example.com ``` Browsers interpret this value as an external URL and redirect the user to `https://evil.example.com`. ## Details The shared `createURL()` helper is used by route URL builders, including `Router.makeUrl()` and `Response.redirect().toRoute()`. Route parameter values were appended without encoding: ```ts if (isDefined) { uriSegments.push(`${value}${token.end}`) } ``` Wildcard parameters had the same behavior: ```ts uriSegments.push(`${values.join('/')}${token.end}`) ``` **The issue does not affect APIs that intentionally accept complete redirect URLs. Exploitation requires an application to pass attacker-controlled data as a route parameter and use the generated URL as a redirect destination.** ## Impact An attacker may craft a link on a trusted application domain that redirects a victim to an attacker-controlled website. This can facilitate phishing and may be chained with authentication or OAuth flows that rely on trusted redirect destinations. Applications are affected when they: - define a route whose first path segment is dynamic; and

osv:GHSA-2m6q-8v3h-jqww

@adonisjs/http-server

Fixed versions: 9.3.0

@adonisjs/http-server

Fixed versions: 8.2.3

Complete source record
{
  "id": "5d54bdea56a4c3a6c9d024991944afe6f137a64510ff8538f85a8f07042a7e78",
  "url": "https://osv.dev/vulnerability/GHSA-2m6q-8v3h-jqww",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "AdonisJS: Unencoded route parameters can produce open redirects",
    "summary": "Route parameters are inserted into generated URLs without URI encoding. When an application passes untrusted input to a route whose first path segment is dynamic, a value beginning with / can produce a scheme-relative URL. For example: ```ts router.get('/:page', handler).as('pages.show') response.redirect().toRoute('pages.show', { page: '/evil.example.com', }) ``` This generates the following redirect: ```http Location: //evil.example.com ``` Browsers interpret this value as an external URL and redirect the user to `https://evil.example.com`. ## Details The shared `createURL()` helper is used by route URL builders, including `Router.makeUrl()` and `Response.redirect().toRoute()`. Route parameter values were appended without encoding: ```ts if (isDefined) { uriSegments.push(`${value}${token.end}`) } ``` Wildcard parameters had the same behavior: ```ts uriSegments.push(`${values.join('/')}${token.end}`) ``` **The issue does not affect APIs that intentionally accept complete redirect URLs. Exploitation requires an application to pass attacker-controlled data as a route parameter and use the generated URL as a redirect destination.** ## Impact An attacker may craft a link on a trusted application domain that redirects a victim to an attacker-controlled website. This can facilitate phishing and may be chained with authentication or OAuth flows that rely on trusted redirect destinations. Applications are affected when they: - define a route whose first path segment is dynamic; and ",
    "evidence": "osv:GHSA-2m6q-8v3h-jqww",
    "products": [
      {
        "name": {
          "value": "@adonisjs/http-server",
          "evidence": "/affected/0/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [
          {
            "value": "9.3.0",
            "evidence": "/affected/0/ranges"
          }
        ],
        "affected_versions": []
      },
      {
        "name": {
          "value": "@adonisjs/http-server",
          "evidence": "/affected/1/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [
          {
            "value": "8.2.3",
            "evidence": "/affected/1/ranges"
          }
        ],
        "affected_versions": []
      }
    ],
    "severity": "medium",
    "structured": {
      "id": "GHSA-2m6q-8v3h-jqww",
      "aliases": [
        "CVE-2026-107718",
        "GHSA-2m6q-8v3h-jqww"
      ],
      "metrics": [
        {
          "type": "CVSS_V3",
          "score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "type": "SEMVER",
              "events": [
                {
                  "introduced": "9.0.0"
                },
                {
                  "fixed": "9.3.0"
                }
              ]
            }
          ],
          "package": {
            "name": "@adonisjs/http-server",
            "purl": "pkg:npm/%40adonisjs/http-server",
            "ecosystem": "npm"
          },
          "database_specific": {
            "source": "https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/10/GHSA-2m6q-8v3h-jqww/GHSA-2m6q-8v3h-jqww.json",
            "last_known_affected_version_range": "<= 9.2.0"
          }
        },
        {
          "ranges": [
            {
              "type": "SEMVER",
              "events": [
                {
                  "introduced": "0"
                },
                {
                  "fixed": "8.2.3"
                }
              ]
            }
          ],
          "package": {
            "name": "@adonisjs/http-server",
            "purl": "pkg:npm/%40adonisjs/http-server",
            "ecosystem": "npm"
          },
          "database_specific": {
            "source": "https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/10/GHSA-2m6q-8v3h-jqww/GHSA-2m6q-8v3h-jqww.json",
            "last_known_affected_version_range": "<= 8.2.2"
          }
        }
      ],
      "modified": "2026-10-08T22:30:09.030589206Z",
      "provider": "osv",
      "references": [
        "https://github.com/adonisjs/http-server/security/advisories/GHSA-2m6q-8v3h-jqww",
        "https://github.com/adonisjs/http-server/commit/4548a0631ce2ef1618f04c7b41465be42cad2f7d",
        "https://github.com/adonisjs/http-server/commit/ab607a2958327b6f0019d38f26081e431768877a",
        "https://github.com/adonisjs/http-server",
        "https://github.com/adonisjs/http-server/releases/tag/v8.2.3",
        "https://github.com/adonisjs/http-server/releases/tag/v9.3.0"
      ],
      "provider_metadata": {
        "cwe_ids": [
          "CWE-601"
        ],
        "severity": "MODERATE",
        "github_reviewed": true,
        "nvd_published_at": null,
        "github_reviewed_at": "2026-10-08T22:09:06Z"
      }
    },
    "related_cves": [
      {
        "value": "CVE-2026-107718",
        "evidence": "/aliases"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 104889,
  "published_at": "2026-10-08T22:09:06+00:00"
}