CVE-2026-107718: AdonisJS: Unencoded route parameters can produce open redirects

Published Oct 8, 2026
·
Updated

AdonisJS HTTP Server is a package for handling HTTP requests in the AdonisJS framework. Prior to 8.2.3 and 9.3.0, AdonisJS HTTP Server inserts route parameter values into URLs without encodeURIComponent in the shared createURL() helper used by Router.makeUrl() and Response.redirect().toRoute(). If an application places attacker-controlled data in a dynamic first path segment and uses the generated route URL as a redirect destination, a value beginning with a slash can produce a scheme-relative external URL. Wildcard parameters are affected by the same missing encoding, while APIs intentionally accepting complete redirect URLs are not affected. An attacker can redirect users from a trusted application to an attacker-controlled site, facilitating phishing or abuse of authentication and OAuth flows. This issue is fixed in versions 8.2.3 and 9.3.0.

Other sources

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 - pass request-derived data to that segment when generating a redirect URL.

Patches

Route parameter values are now encoded using encodeURIComponent.

Wildcard values are encoded individually before being joined with /, preserving their intended segment separators:

ts if (isDefined) { uriSegments.push(${encodeURIComponent(String(value))}${token.end}) }

ts uriSegments.push( ${values.map((value) => encodeURIComponent(String(value))).join('/')}${token.end} )

With the fix, /evil.example.com becomes:

/%2Fevil.example.com

Fixes targeting v6 and v7 have been published below. - https://github.com/adonisjs/http-server/releases/tag/v8.2.3 - https://github.com/adonisjs/http-server/releases/tag/v9.3.0

— GitHub

Affected Software

3 affected componentsFixes available
npm/@adonisjs/http-server<8.2.3, <9.3.0
npm/@adonisjs/http-server<=8.2.2
8.2.3
npm/@adonisjs/http-server>=9.0.0<=9.2.0
9.3.0

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade npm/@adonisjs/http-server to a version that resolves this vulnerability.

    Fixed in 8.2.3
  2. Upgrade

    Upgrade npm/@adonisjs/http-server to a version that resolves this vulnerability.

    Fixed in 9.3.0
  3. Upgrade

    Upgrade AdonisJS HTTP Server to a version that resolves this vulnerability.

    Fixed in 8.2.3
  4. Upgrade

    Upgrade AdonisJS HTTP Server to a version that resolves this vulnerability.

    Fixed in 9.3.0

Event History

Oct 8, 2026
CVE Published
via MITRE·09:39 PM
Data Sourced
via MITRE·09:39 PM
DescriptionSeverityWeakness
Advisory Published
via GitHub·10:09 PM
Data Sourced
via GitHub·10:09 PM
DescriptionSeverityWeaknessAffected Software

Frequently Asked Questions

1

Which applications are realistically exposed to this issue?

Applications using affected AdonisJS HTTP Server versions are exposed only when attacker-controlled data is placed in a dynamic first path segment or wildcard parameter and a URL generated by Router.makeUrl() or Response.redirect().toRoute() is used as a redirect destination.

2

What does an attacker need to exploit it?

An attacker needs to control a route parameter value used in the generated redirect URL and induce a user to follow the resulting redirect. A value beginning with a slash can cause the destination to become a scheme-relative URL pointing to an external site.

3

Are redirect APIs that intentionally accept full URLs affected?

No. APIs intentionally designed to accept complete redirect URLs are not affected by this missing route-parameter encoding issue.

4

What versions contain the fix?

The issue is fixed in AdonisJS HTTP Server versions 8.2.3 and 9.3.0. Versions prior to those releases are affected under the vulnerable redirect pattern.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203