@socketsecurity/cli-with-sentry 0.14.110 → 0.14.112
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/dist/instrument-with-sentry.js +2 -2
- package/dist/instrument-with-sentry.js.map +1 -1
- package/dist/module-sync/cli.js +52 -49
- package/dist/module-sync/cli.js.map +1 -1
- package/dist/module-sync/shadow-npm-inject.js +27 -23
- package/dist/module-sync/shadow-npm-inject.js.map +1 -1
- package/dist/require/cli.js +52 -49
- package/dist/require/cli.js.map +1 -1
- package/dist/require/shadow-npm-inject.js +27 -23
- package/dist/require/shadow-npm-inject.js.map +1 -1
- package/package.json +1 -1
package/dist/require/cli.js
CHANGED
|
@@ -917,7 +917,7 @@ function emitBanner(name) {
|
|
|
917
917
|
logger.logger.error(getAsciiHeader(name))
|
|
918
918
|
}
|
|
919
919
|
function getAsciiHeader(command) {
|
|
920
|
-
const cliVersion = '0.14.
|
|
920
|
+
const cliVersion = '0.14.112:79a6e07:49616d8e:pub' // The '@rollup/plugin-replace' will replace "process.env['INLINED_SOCKET_CLI_VERSION_HASH']".
|
|
921
921
|
const nodeVersion = process$1.version
|
|
922
922
|
const apiToken = shadowNpmInject.getDefaultToken()
|
|
923
923
|
const defaultOrg = shadowNpmInject.getConfigValue('defaultOrg')
|
|
@@ -3728,7 +3728,10 @@ const cmdDiffScan = {
|
|
|
3728
3728
|
|
|
3729
3729
|
const { GITHUB_REF_NAME } = constants
|
|
3730
3730
|
function formatBranchName(str) {
|
|
3731
|
-
return str
|
|
3731
|
+
return str
|
|
3732
|
+
.replace(/[-_.\\/]+/g, '-')
|
|
3733
|
+
.replace(/[^-a-zA-Z0-9]+/g, '')
|
|
3734
|
+
.replace(/^-+|-+$/g, '')
|
|
3732
3735
|
}
|
|
3733
3736
|
function getPkgNameFromPurlObj(purlObj) {
|
|
3734
3737
|
return `${purlObj.namespace ? `${purlObj.namespace}/` : ''}${purlObj.name}`
|
|
@@ -4094,28 +4097,28 @@ async function npmFix(
|
|
|
4094
4097
|
firstPatchedVersionIdentifier,
|
|
4095
4098
|
vulnerableVersionRange
|
|
4096
4099
|
} of infos) {
|
|
4097
|
-
const revertTree = arb.idealTree
|
|
4098
|
-
arb.idealTree = null
|
|
4099
|
-
// eslint-disable-next-line no-await-in-loop
|
|
4100
|
-
await arb.buildIdealTree()
|
|
4101
|
-
const node = shadowNpmInject.findPackageNode(
|
|
4102
|
-
arb.idealTree,
|
|
4103
|
-
name,
|
|
4104
|
-
oldVersion
|
|
4105
|
-
)
|
|
4106
|
-
if (!node) {
|
|
4107
|
-
continue
|
|
4108
|
-
}
|
|
4109
|
-
if (
|
|
4110
|
-
!shadowNpmInject.updateNode(node, packument, vulnerableVersionRange)
|
|
4111
|
-
) {
|
|
4112
|
-
if (!unavailableSpecs.has(oldSpec)) {
|
|
4113
|
-
unavailableSpecs.add(oldSpec)
|
|
4114
|
-
spinner?.fail(`No update available for ${oldSpec}`)
|
|
4115
|
-
}
|
|
4116
|
-
continue
|
|
4117
|
-
}
|
|
4118
4100
|
for (const pkgJsonPath of pkgJsonPaths) {
|
|
4101
|
+
const revertTree = arb.idealTree
|
|
4102
|
+
arb.idealTree = null
|
|
4103
|
+
// eslint-disable-next-line no-await-in-loop
|
|
4104
|
+
await arb.buildIdealTree()
|
|
4105
|
+
const node = shadowNpmInject.findPackageNode(
|
|
4106
|
+
arb.idealTree,
|
|
4107
|
+
name,
|
|
4108
|
+
oldVersion
|
|
4109
|
+
)
|
|
4110
|
+
if (!node) {
|
|
4111
|
+
continue
|
|
4112
|
+
}
|
|
4113
|
+
if (
|
|
4114
|
+
!shadowNpmInject.updateNode(node, packument, vulnerableVersionRange)
|
|
4115
|
+
) {
|
|
4116
|
+
if (!unavailableSpecs.has(oldSpec)) {
|
|
4117
|
+
unavailableSpecs.add(oldSpec)
|
|
4118
|
+
spinner?.fail(`No update available for ${oldSpec}`)
|
|
4119
|
+
}
|
|
4120
|
+
continue
|
|
4121
|
+
}
|
|
4119
4122
|
const isWorkspaceRoot =
|
|
4120
4123
|
pkgJsonPath === pkgEnvDetails.editablePkgJson.filename
|
|
4121
4124
|
const workspaceName = isWorkspaceRoot
|
|
@@ -4513,32 +4516,32 @@ async function pnpmFix(
|
|
|
4513
4516
|
firstPatchedVersionIdentifier,
|
|
4514
4517
|
vulnerableVersionRange
|
|
4515
4518
|
} of infos) {
|
|
4516
|
-
const node = shadowNpmInject.findPackageNode(
|
|
4517
|
-
actualTree,
|
|
4518
|
-
name,
|
|
4519
|
-
oldVersion
|
|
4520
|
-
)
|
|
4521
|
-
if (!node) {
|
|
4522
|
-
continue
|
|
4523
|
-
}
|
|
4524
|
-
const availableVersions = Object.keys(packument.versions)
|
|
4525
|
-
const newVersion = shadowNpmInject.findBestPatchVersion(
|
|
4526
|
-
node,
|
|
4527
|
-
availableVersions,
|
|
4528
|
-
vulnerableVersionRange
|
|
4529
|
-
)
|
|
4530
|
-
const newVersionPackument = newVersion
|
|
4531
|
-
? packument.versions[newVersion]
|
|
4532
|
-
: undefined
|
|
4533
|
-
if (!(newVersion && newVersionPackument)) {
|
|
4534
|
-
if (!unavailableSpecs.has(oldSpec)) {
|
|
4535
|
-
unavailableSpecs.add(oldSpec)
|
|
4536
|
-
spinner?.fail(`No update available for ${oldSpec}`)
|
|
4537
|
-
}
|
|
4538
|
-
continue
|
|
4539
|
-
}
|
|
4540
4519
|
debug.debugLog('pkgJsonPaths', pkgJsonPaths)
|
|
4541
4520
|
for (const pkgJsonPath of pkgJsonPaths) {
|
|
4521
|
+
const node = shadowNpmInject.findPackageNode(
|
|
4522
|
+
actualTree,
|
|
4523
|
+
name,
|
|
4524
|
+
oldVersion
|
|
4525
|
+
)
|
|
4526
|
+
if (!node) {
|
|
4527
|
+
continue
|
|
4528
|
+
}
|
|
4529
|
+
const availableVersions = Object.keys(packument.versions)
|
|
4530
|
+
const newVersion = shadowNpmInject.findBestPatchVersion(
|
|
4531
|
+
node,
|
|
4532
|
+
availableVersions,
|
|
4533
|
+
vulnerableVersionRange
|
|
4534
|
+
)
|
|
4535
|
+
const newVersionPackument = newVersion
|
|
4536
|
+
? packument.versions[newVersion]
|
|
4537
|
+
: undefined
|
|
4538
|
+
if (!(newVersion && newVersionPackument)) {
|
|
4539
|
+
if (!unavailableSpecs.has(oldSpec)) {
|
|
4540
|
+
unavailableSpecs.add(oldSpec)
|
|
4541
|
+
spinner?.fail(`No update available for ${oldSpec}`)
|
|
4542
|
+
}
|
|
4543
|
+
continue
|
|
4544
|
+
}
|
|
4542
4545
|
const isWorkspaceRoot =
|
|
4543
4546
|
pkgJsonPath === pkgEnvDetails.editablePkgJson.filename
|
|
4544
4547
|
const workspaceName = isWorkspaceRoot
|
|
@@ -12309,7 +12312,7 @@ void (async () => {
|
|
|
12309
12312
|
await vendor.updater({
|
|
12310
12313
|
name: SOCKET_CLI_BIN_NAME,
|
|
12311
12314
|
// The '@rollup/plugin-replace' will replace "process.env['INLINED_SOCKET_CLI_VERSION']".
|
|
12312
|
-
version: '0.14.
|
|
12315
|
+
version: '0.14.112',
|
|
12313
12316
|
ttl: 86_400_000 /* 24 hours in milliseconds */
|
|
12314
12317
|
})
|
|
12315
12318
|
try {
|
|
@@ -12377,5 +12380,5 @@ void (async () => {
|
|
|
12377
12380
|
await shadowNpmInject.captureException(e)
|
|
12378
12381
|
}
|
|
12379
12382
|
})()
|
|
12380
|
-
//# debugId=
|
|
12383
|
+
//# debugId=d1400c3c-29d5-4f5d-9766-57e761274a4b
|
|
12381
12384
|
//# sourceMappingURL=cli.js.map
|