CVE-2026-49983: CWE-863: Incorrect Authorization in denoland deno
Deno is a JavaScript, TypeScript, and WebAssembly runtime. Prior to 2.8.1, environment access is gated by the env permission. You can deny it with --deny-env, or restrict it to a specific allowlist with --allow-env=FOO,BAR. The expectation is that a program running without env permission cannot change process.env. process.loadEnvFile() (the Node-compatible API for loading variables from a .env file) does not honor this. It only checks that the program has read permission for the dotenv file, then writes every key in that file into the process environment — even when env access is denied. In effect, --allow-read plus a writable or attacker-controlled .env file is enough to defeat --deny-env. This vulnerability is fixed in 2.8.1.
AI Analysis
Technical Summary
Deno is a runtime for JavaScript, TypeScript, and WebAssembly that uses permission flags to control environment access. Before version 2.8.1, the process.loadEnvFile() function, which loads environment variables from a .env file, does not honor the env permission restrictions. It only verifies read permission on the .env file and then writes all keys into the process environment regardless of the --deny-env flag. Consequently, an attacker who can read and modify a .env file can bypass the intended environment access restrictions, leading to incorrect authorization (CWE-863). This vulnerability is resolved in Deno 2.8.1.
Potential Impact
An attacker with read access and control over a .env file can bypass the environment access restrictions enforced by the --deny-env flag, potentially injecting environment variables into the process. This could lead to partial confidentiality and integrity impacts on environment variables, but does not affect availability. The CVSS 3.1 base score is 5.2 (medium severity), reflecting local attack vector with low complexity and privileges required, no user interaction, and partial confidentiality and integrity impact.
Mitigation Recommendations
This vulnerability is fixed in Deno version 2.8.1. Users should upgrade to version 2.8.1 or later to ensure that process.loadEnvFile() respects the env permission restrictions. Until upgraded, avoid running untrusted code with --allow-read permission on attacker-controlled .env files when using --deny-env. Patch status is confirmed fixed in 2.8.1.
CVE-2026-49983: CWE-863: Incorrect Authorization in denoland deno
Description
Deno is a JavaScript, TypeScript, and WebAssembly runtime. Prior to 2.8.1, environment access is gated by the env permission. You can deny it with --deny-env, or restrict it to a specific allowlist with --allow-env=FOO,BAR. The expectation is that a program running without env permission cannot change process.env. process.loadEnvFile() (the Node-compatible API for loading variables from a .env file) does not honor this. It only checks that the program has read permission for the dotenv file, then writes every key in that file into the process environment — even when env access is denied. In effect, --allow-read plus a writable or attacker-controlled .env file is enough to defeat --deny-env. This vulnerability is fixed in 2.8.1.
CVSS v3.1
Score 5.2medium
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
Deno is a runtime for JavaScript, TypeScript, and WebAssembly that uses permission flags to control environment access. Before version 2.8.1, the process.loadEnvFile() function, which loads environment variables from a .env file, does not honor the env permission restrictions. It only verifies read permission on the .env file and then writes all keys into the process environment regardless of the --deny-env flag. Consequently, an attacker who can read and modify a .env file can bypass the intended environment access restrictions, leading to incorrect authorization (CWE-863). This vulnerability is resolved in Deno 2.8.1.
Potential Impact
An attacker with read access and control over a .env file can bypass the environment access restrictions enforced by the --deny-env flag, potentially injecting environment variables into the process. This could lead to partial confidentiality and integrity impacts on environment variables, but does not affect availability. The CVSS 3.1 base score is 5.2 (medium severity), reflecting local attack vector with low complexity and privileges required, no user interaction, and partial confidentiality and integrity impact.
Mitigation Recommendations
This vulnerability is fixed in Deno version 2.8.1. Users should upgrade to version 2.8.1 or later to ensure that process.loadEnvFile() respects the env permission restrictions. Until upgraded, avoid running untrusted code with --allow-read permission on attacker-controlled .env files when using --deny-env. Patch status is confirmed fixed in 2.8.1.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2026-06-02T18:30:51.282Z
- Cvss Version
- 3.1
- State
- PUBLISHED
- Remediation Level
- null
Threat ID: 6a3ac4f0eed863c81e61824e
Added to database: 06/23/2026, 17:40:00 UTC
Last enriched: 06/23/2026, 17:55:04 UTC
Last updated: 08/06/2026, 00:41:13 UTC
Views: 51
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
External Links
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.