socket 1.4.1 → 1.5.0

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
@@ -4,6 +4,19 @@ All notable changes to this project will be documented in this file.
4
4
 
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
6
6
 
7
+ ## [1.5.0](https://github.com/SocketDev/socket-cli/releases/tag/v1.5.0) - 2026-10-06
8
+
9
+ ### Added
10
+ - `socket fix --allow-overrides` fixes a vulnerability that a parent package's version range blocks by writing an override or resolution that forces the fixed version under that parent, in npm, pnpm, Yarn Berry and Rush projects.
11
+
12
+ ### Changed
13
+ - Updated the Coana CLI to v `15.12.0`.
14
+
15
+ ## [1.4.2](https://github.com/SocketDev/socket-cli/releases/tag/v1.4.2) - 2026-10-05
16
+
17
+ ### Changed
18
+ - Updated the Coana CLI to v `15.11.6`.
19
+
7
20
  ## [1.4.1](https://github.com/SocketDev/socket-cli/releases/tag/v1.4.1) - 2026-09-30
8
21
 
9
22
  ### Changed
package/README.md CHANGED
@@ -1,8 +1,8 @@
1
1
  # Socket CLI
2
2
 
3
3
  [![Socket Badge](https://socket.dev/api/badge/npm/package/socket)](https://socket.dev/npm/package/socket)
4
- [![Follow @SocketSecurity](https://raw.githubusercontent.com/SocketDev/socket-cli/v1.4.1/assets/fleet/badge-follow-x.svg)](https://twitter.com/SocketSecurity)
5
- [![Follow @socket.dev on Bluesky](https://raw.githubusercontent.com/SocketDev/socket-cli/v1.4.1/assets/fleet/badge-follow-bluesky.svg)](https://bsky.app/profile/socket.dev)
4
+ [![Follow @SocketSecurity](https://raw.githubusercontent.com/SocketDev/socket-cli/v1.5.0/assets/fleet/badge-follow-x.svg)](https://twitter.com/SocketSecurity)
5
+ [![Follow @socket.dev on Bluesky](https://raw.githubusercontent.com/SocketDev/socket-cli/v1.5.0/assets/fleet/badge-follow-bluesky.svg)](https://bsky.app/profile/socket.dev)
6
6
 
7
7
  CLI for [Socket.dev](https://socket.dev) — scan dependencies, audit packages, apply security patches, and gate installs from your terminal or CI. This is the 1.x line of the published `socket` package on npm.
8
8
 
@@ -171,8 +171,8 @@ MIT
171
171
  <br/>
172
172
  <div align="center">
173
173
  <picture>
174
- <source media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/SocketDev/socket-cli/v1.4.1/assets/fleet/socket-combomark-dark.svg">
175
- <source media="(prefers-color-scheme: light)" srcset="https://raw.githubusercontent.com/SocketDev/socket-cli/v1.4.1/assets/fleet/socket-combomark-light.svg">
176
- <img width="324" height="104" alt="Socket" src="https://raw.githubusercontent.com/SocketDev/socket-cli/v1.4.1/assets/fleet/socket-combomark-light.svg">
174
+ <source media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/SocketDev/socket-cli/v1.5.0/assets/fleet/socket-combomark-dark.svg">
175
+ <source media="(prefers-color-scheme: light)" srcset="https://raw.githubusercontent.com/SocketDev/socket-cli/v1.5.0/assets/fleet/socket-combomark-light.svg">
176
+ <img width="324" height="104" alt="Socket" src="https://raw.githubusercontent.com/SocketDev/socket-cli/v1.5.0/assets/fleet/socket-combomark-light.svg">
177
177
  </picture>
178
178
  </div>
package/dist/cli.js CHANGED
@@ -9016,6 +9016,7 @@ async function coanaFix(fixConfig) {
9016
9016
  async function coanaFixWithFacts(fixConfig, factsSlot) {
9017
9017
  const {
9018
9018
  all,
9019
+ allowOverrides,
9019
9020
  applyFixes,
9020
9021
  autopilot,
9021
9022
  coanaVersion,
@@ -9204,7 +9205,7 @@ async function coanaFixWithFacts(fixConfig, factsSlot) {
9204
9205
  const tmpDir = os.tmpdir();
9205
9206
  const tmpFile = path.join(tmpDir, `socket-fix-${Date.now()}.json`);
9206
9207
  try {
9207
- const fixCResult = await utils.spawnCoanaDlx(['compute-fixes-and-upgrade-purls', cwd, '--manifests-tar-hash', tarHash, '--apply-fixes-to', ...ids, ...(fixConfig.rangeStyle ? ['--range-style', fixConfig.rangeStyle] : []), ...(minimumReleaseAge ? ['--minimum-release-age', minimumReleaseAge] : []), ...(include.length ? ['--include', ...include] : []), ...(coanaExcludePatterns.length ? ['--exclude', ...coanaExcludePatterns] : []), ...(ecosystems.length ? ['--purl-types', ...ecosystems] : []), ...(packageManagers.length ? ['--package-managers', ...packageManagers] : []), ...factsFlags, ...(!applyFixes ? [constants.FLAG_DRY_RUN] : []), '--output-file', tmpFile, ...(debug$1 ? ['--debug'] : []), ...(disableExternalToolChecks ? ['--disable-external-tool-checks'] : []), ...(disableMajorUpdates ? ['--disable-major-updates'] : []), ...(showAffectedDirectDependencies ? ['--show-affected-direct-dependencies'] : []), ...fixConfig.unknownFlags], fixConfig.orgSlug, {
9208
+ const fixCResult = await utils.spawnCoanaDlx(['compute-fixes-and-upgrade-purls', cwd, '--manifests-tar-hash', tarHash, '--apply-fixes-to', ...ids, ...(fixConfig.rangeStyle ? ['--range-style', fixConfig.rangeStyle] : []), ...(minimumReleaseAge ? ['--minimum-release-age', minimumReleaseAge] : []), ...(include.length ? ['--include', ...include] : []), ...(coanaExcludePatterns.length ? ['--exclude', ...coanaExcludePatterns] : []), ...(ecosystems.length ? ['--purl-types', ...ecosystems] : []), ...(packageManagers.length ? ['--package-managers', ...packageManagers] : []), ...factsFlags, ...(!applyFixes ? [constants.FLAG_DRY_RUN] : []), '--output-file', tmpFile, ...(debug$1 ? ['--debug'] : []), ...(disableExternalToolChecks ? ['--disable-external-tool-checks'] : []), ...(disableMajorUpdates ? ['--disable-major-updates'] : []), ...(allowOverrides ? ['--allow-overrides'] : []), ...(showAffectedDirectDependencies ? ['--show-affected-direct-dependencies'] : []), ...fixConfig.unknownFlags], fixConfig.orgSlug, {
9208
9209
  coanaVersion,
9209
9210
  cwd,
9210
9211
  spinner: silence ? undefined : spinner,
@@ -9335,7 +9336,7 @@ async function coanaFixWithFacts(fixConfig, factsSlot) {
9335
9336
 
9336
9337
  // Apply fix for single GHSA ID.
9337
9338
  // eslint-disable-next-line no-await-in-loop
9338
- const fixCResult = await utils.spawnCoanaDlx(['compute-fixes-and-upgrade-purls', cwd, '--manifests-tar-hash', tarHash, '--apply-fixes-to', ghsaId, ...(fixConfig.rangeStyle ? ['--range-style', fixConfig.rangeStyle] : []), ...(minimumReleaseAge ? ['--minimum-release-age', minimumReleaseAge] : []), ...(include.length ? ['--include', ...include] : []), ...(coanaExcludePatterns.length ? ['--exclude', ...coanaExcludePatterns] : []), ...(ecosystems.length ? ['--purl-types', ...ecosystems] : []), ...(packageManagers.length ? ['--package-managers', ...packageManagers] : []), ...factsFlags, ...(debug$1 ? ['--debug'] : []), ...(disableExternalToolChecks ? ['--disable-external-tool-checks'] : []), ...(disableMajorUpdates ? ['--disable-major-updates'] : []), ...(showAffectedDirectDependencies ? ['--show-affected-direct-dependencies'] : []), '--output-file', tmpFile, ...fixConfig.unknownFlags], fixConfig.orgSlug, {
9339
+ const fixCResult = await utils.spawnCoanaDlx(['compute-fixes-and-upgrade-purls', cwd, '--manifests-tar-hash', tarHash, '--apply-fixes-to', ghsaId, ...(fixConfig.rangeStyle ? ['--range-style', fixConfig.rangeStyle] : []), ...(minimumReleaseAge ? ['--minimum-release-age', minimumReleaseAge] : []), ...(include.length ? ['--include', ...include] : []), ...(coanaExcludePatterns.length ? ['--exclude', ...coanaExcludePatterns] : []), ...(ecosystems.length ? ['--purl-types', ...ecosystems] : []), ...(packageManagers.length ? ['--package-managers', ...packageManagers] : []), ...factsFlags, ...(debug$1 ? ['--debug'] : []), ...(disableExternalToolChecks ? ['--disable-external-tool-checks'] : []), ...(disableMajorUpdates ? ['--disable-major-updates'] : []), ...(allowOverrides ? ['--allow-overrides'] : []), ...(showAffectedDirectDependencies ? ['--show-affected-direct-dependencies'] : []), '--output-file', tmpFile, ...fixConfig.unknownFlags], fixConfig.orgSlug, {
9339
9340
  coanaVersion,
9340
9341
  cwd,
9341
9342
  spinner: silence ? undefined : spinner,
@@ -9665,6 +9666,7 @@ async function convertIdsToGhsas(ids, options) {
9665
9666
  }
9666
9667
  async function handleFix({
9667
9668
  all,
9669
+ allowOverrides,
9668
9670
  applyFixes,
9669
9671
  autopilot,
9670
9672
  coanaVersion,
@@ -9695,6 +9697,7 @@ async function handleFix({
9695
9697
  debug.debugFn('notice', `Starting fix command for ${orgSlug}`);
9696
9698
  debug.debugDir('inspect', {
9697
9699
  all,
9700
+ allowOverrides,
9698
9701
  applyFixes,
9699
9702
  autopilot,
9700
9703
  coanaVersion,
@@ -9722,6 +9725,7 @@ async function handleFix({
9722
9725
  });
9723
9726
  await outputFixResult(await coanaFix({
9724
9727
  all,
9728
+ allowOverrides,
9725
9729
  applyFixes,
9726
9730
  autopilot,
9727
9731
  coanaVersion,
@@ -9884,6 +9888,11 @@ const cmdFix = {
9884
9888
  run: run$N
9885
9889
  };
9886
9890
  const generalFlags$2 = {
9891
+ allowOverrides: {
9892
+ type: 'boolean',
9893
+ default: false,
9894
+ description: "When the only fix for a vulnerability is blocked by a parent package's declared version range, write an override or resolution that forces the fixed version under that parent. This can install a version outside the range the parent declares, so test the parent afterwards. Works for npm, pnpm, Yarn Berry and Rush projects."
9895
+ },
9887
9896
  autopilot: {
9888
9897
  type: 'boolean',
9889
9898
  default: false,
@@ -10119,6 +10128,7 @@ async function run$N(argv, importMeta, {
10119
10128
  });
10120
10129
  const {
10121
10130
  all,
10131
+ allowOverrides,
10122
10132
  applyFixes,
10123
10133
  autopilot,
10124
10134
  debug,
@@ -10249,6 +10259,7 @@ async function run$N(argv, importMeta, {
10249
10259
  } = constants.default;
10250
10260
  await handleFix({
10251
10261
  all,
10262
+ allowOverrides,
10252
10263
  applyFixes,
10253
10264
  autopilot,
10254
10265
  coanaVersion: fixVersion,
@@ -24420,5 +24431,5 @@ process.on('unhandledRejection', async (reason, promise) => {
24420
24431
  // eslint-disable-next-line n/no-process-exit
24421
24432
  process.exit(1);
24422
24433
  });
24423
- //# debugId=71bcae26-79e9-4006-9570-248817c517a
24434
+ //# debugId=49b84e0d-2ad3-4172-ac33-4d007769e3c8
24424
24435
  //# sourceMappingURL=cli.js.map