@dotenvx/dotenvx 1.61.5 → 1.61.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -2,7 +2,13 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
- [Unreleased](https://github.com/dotenvx/dotenvx/compare/v1.61.5...main)
5
+ [Unreleased](https://github.com/dotenvx/dotenvx/compare/v1.61.6...main)
6
+
7
+ ## [1.61.6](https://github.com/dotenvx/dotenvx/compare/v1.61.5...v1.61.6) (2026-04-23)
8
+
9
+ ### Changed
10
+
11
+ * Guard against command substitution following `encrypted:` ([#802](https://github.com/dotenvx/dotenvx/pull/802))
6
12
 
7
13
  ## [1.61.5](https://github.com/dotenvx/dotenvx/compare/v1.61.4...v1.61.5) (2026-04-22)
8
14
 
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "1.61.5",
2
+ "version": "1.61.6",
3
3
  "name": "@dotenvx/dotenvx",
4
4
  "description": "secrets for agents–from the creator of `dotenv`",
5
5
  "author": "@motdotla",
@@ -23,7 +23,7 @@ function executeExtension (ext, command, rawArgs) {
23
23
  const result = childProcess.spawnSync(`dotenvx-ext-${command}`, forwardedArgs, { stdio: 'inherit', env })
24
24
  if (result.error) {
25
25
  // list known extension here for convenience to the user
26
- if (['vault', 'hub'].includes(command)) {
26
+ if (['vault'].includes(command)) {
27
27
  logger.warn(`[INSTALLATION_NEEDED] install dotenvx-ext-${command} to use [dotenvx ext ${command}] commands`)
28
28
  logger.help('? see installation instructions [https://github.com/dotenvx/dotenvx-ext-vault]')
29
29
  } else {
@@ -1,4 +1,5 @@
1
1
  const decryptKeyValue = require('./cryptography/decryptKeyValue')
2
+ const isEncrypted = require('./cryptography/isEncrypted')
2
3
  const evalKeyValue = require('./evalKeyValue')
3
4
  const resolveEscapeSequences = require('./resolveEscapeSequences')
4
5
 
@@ -44,9 +45,11 @@ class Parse {
44
45
  this.errors.push(e)
45
46
  }
46
47
 
48
+ const encryptedPrefixed = isEncrypted(this.parsed[key]) // do not eval encrypted prefix
49
+
47
50
  // eval empty, double, or backticks
48
51
  let evaled = false
49
- if (quote !== "'" && (!this.inProcessEnv(key) || this.processEnv[key] === this.parsed[key])) {
52
+ if (!encryptedPrefixed && quote !== "'" && (!this.inProcessEnv(key) || this.processEnv[key] === this.parsed[key])) {
50
53
  const priorEvaled = this.parsed[key]
51
54
  // eval
52
55
  try {
@@ -60,7 +63,7 @@ class Parse {
60
63
  }
61
64
 
62
65
  // expand empty, double, or backticks
63
- if (!evaled && quote !== "'" && (!this.processEnv[key] || this.overload)) {
66
+ if (!encryptedPrefixed && !evaled && quote !== "'" && (!this.processEnv[key] || this.overload)) {
64
67
  this.parsed[key] = resolveEscapeSequences(this.expand(this.parsed[key]))
65
68
  }
66
69
 
package/src/lib/main.js CHANGED
@@ -103,7 +103,7 @@ const config = function (options = {}) {
103
103
  }
104
104
  }
105
105
 
106
- let msg = `injecting env (${uniqueInjectedKeys.length})`
106
+ let msg = `injected env (${uniqueInjectedKeys.length})`
107
107
  if (readableFilepaths.length > 0) {
108
108
  msg += ` from ${readableFilepaths.join(', ')}`
109
109
  }