CVE-2026-40255: Open Redirect Vulnerability in @adonisjs/http-server

@adonisjs/http-server Updated 14 Apr 2026

Summary

14/04/2026
Yes i
Moderate
6.1

CVE-2026-40255: URL Redirection to Untrusted Site ('Open Redirect') in @adonisjs/http-server. Affects @adonisjs/http-server across 2 version ranges.

< 7.8.1 >= 8.0.0-next.0, < 8.2.0

Fixed in 7.8.1 or 8.2.0, depending on the release line you run. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Lume, the Habilume companion Habilume Habit tracker with a companion that grows with you Complete habits, earn Lume Points, and watch your Lume grow as you stay consistent. App Store Google Play

Background

The @adonisjs/http-server package is a core component of the AdonisJS framework, designed to handle HTTP requests and responses in web applications. It provides various methods for managing responses, including redirection capabilities. However, a flaw in the implementation of the response.redirect().back() method has exposed applications using this package to potential security risks, specifically open redirects.

Vulnerability Detail

The vulnerability arises from the response.redirect().back() method, which reads the Referer header from incoming HTTP requests and redirects users to that URL without validating the host. This lack of validation allows attackers to manipulate the Referer header, potentially redirecting users to malicious external sites. The issue is classified as CWE-601: URL Redirection to Untrusted Site ('Open Redirect'). If exploited, this vulnerability can lead to phishing attacks and loss of user trust.

How To Fix

Latest published version: 9.3.1 as of 22 Oct 2026

npm install @adonisjs/http-server@9.3.1

Upgrading to it may include breaking changes; the versions below are the minimum fixed release for this vulnerability.

If you can't move to the latest

The minimum fixed version depends on the release line you run.

  • < 7.8.1 7.8.1
    npm install @adonisjs/http-server@7.8.1
  • >= 8.0.0-next.0, < 8.2.0 8.2.0
    npm install @adonisjs/http-server@8.2.0

Tip — Not sure which release line you're on? Vulert can find the fix for the version you are using. Scan free →

Workaround

If upgrading is not immediately possible, avoid using response.redirect().back() in routes accessible by unauthenticated users or from pages that accept external traffic. Instead, explicitly redirect to a known safe path using the following code:

response.redirect().toPath('/dashboard');

Conclusion

The CVE-2026-40255 vulnerability in the @adonisjs/http-server package poses a significant risk due to its open redirect capabilities. It is crucial for developers to upgrade to the patched version or implement the suggested workarounds to mitigate potential security threats.

See every vulnerability recorded for @adonisjs/http-server →

Share this vulnerability

FAQ

An open redirect vulnerability allows attackers to redirect users to untrusted sites without proper validation, potentially leading to phishing attacks.

You can check if your application is affected by using the Vulert playground at Vulert Scanner, which monitors open-source vulnerabilities in real-time.

If an upgrade is not feasible, implement the recommended workaround by avoiding the use of response.redirect().back() in vulnerable routes.

The CVSS score for this vulnerability is 6.1, indicating a moderate level of severity.

Additional details can be found in the official advisory on GitHub or by referring to the CWE-601 documentation.

Related vulnerabilities

Recent vulnerabilities recorded for @adonisjs/http-server.

Sponsored Lume, the Habilume companion Habilume Habit tracker with a companion that grows with you Complete habits, earn Lume Points, and watch your Lume grow as you stay consistent. App Store Google Play

How To Fix

Latest published version: 9.3.1 as of 22 Oct 2026

npm install @adonisjs/http-server@9.3.1

Upgrading to it may include breaking changes; the versions below are the minimum fixed release for this vulnerability.

If you can't move to the latest

The minimum fixed version depends on the release line you run.

  • < 7.8.1 7.8.1
    npm install @adonisjs/http-server@7.8.1
  • >= 8.0.0-next.0, < 8.2.0 8.2.0
    npm install @adonisjs/http-server@8.2.0

Tip — Not sure which release line you're on? Vulert can find the fix for the version you are using. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback