snyk 1.1271.0 → 1.1273.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/dist/cli/245.index.js +18 -3
- package/dist/cli/245.index.js.map +1 -1
- package/dist/cli/thirdPartyNotice.json +4 -4
- package/package.json +1 -1
- package/src/generated/sha256sums.txt +8 -8
- package/src/generated/version +1 -1
- package/wrapper_dist/generated/sha256sums.txt +8 -8
- package/wrapper_dist/generated/version +1 -1
package/dist/cli/245.index.js
CHANGED
|
@@ -189564,16 +189564,31 @@ function stripUndefinedLabels(parserResult) {
|
|
|
189564
189564
|
|
|
189565
189565
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
189566
189566
|
exports.phpFilesToScannedProjects = void 0;
|
|
189567
|
-
const lockFileParser = __webpack_require__(59794);
|
|
189568
189567
|
const dep_graph_1 = __webpack_require__(71479);
|
|
189569
189568
|
const path = __webpack_require__(71017);
|
|
189569
|
+
const composer_lockfile_parser_1 = __webpack_require__(59794);
|
|
189570
|
+
const errors_1 = __webpack_require__(18920);
|
|
189570
189571
|
const PACKAGE_MANAGER_TYPE = "composer";
|
|
189571
189572
|
async function phpFilesToScannedProjects(filePathToContent) {
|
|
189572
189573
|
const scanResults = [];
|
|
189573
189574
|
const filePairs = findManifestLockPairsInSameDirectory(filePathToContent);
|
|
189574
189575
|
const shouldIncludeDevDependencies = false;
|
|
189575
189576
|
for (const pathPair of filePairs) {
|
|
189576
|
-
|
|
189577
|
+
let parserResult;
|
|
189578
|
+
try {
|
|
189579
|
+
parserResult = (0, composer_lockfile_parser_1.buildDepTree)(filePathToContent[pathPair.lock], filePathToContent[pathPair.manifest], pathPair.manifest, {}, shouldIncludeDevDependencies);
|
|
189580
|
+
}
|
|
189581
|
+
catch (e) {
|
|
189582
|
+
// This will skip parsing all files that error due to being malformed.
|
|
189583
|
+
// If we do not do this, the entire scan will fail.
|
|
189584
|
+
// Ideally, we'd like to log this, but logging does not exist in this library.
|
|
189585
|
+
if (e instanceof errors_1.InvalidUserInputError) {
|
|
189586
|
+
continue;
|
|
189587
|
+
}
|
|
189588
|
+
else {
|
|
189589
|
+
throw e;
|
|
189590
|
+
}
|
|
189591
|
+
}
|
|
189577
189592
|
const depGraph = await dep_graph_1.legacy.depTreeToGraph(parserResult, PACKAGE_MANAGER_TYPE);
|
|
189578
189593
|
const depGraphFact = {
|
|
189579
189594
|
type: "depGraph",
|
|
@@ -207441,7 +207456,7 @@ function buildArgs(root, targetFile, initGradlePath, options, gradleVersion) {
|
|
|
207441
207456
|
}
|
|
207442
207457
|
// Gradle 7 introduced configuration caching which we don't support yet
|
|
207443
207458
|
// If it is enabled in a gradle.properties file, it can be disabled on the command line with --no-configuration-cache
|
|
207444
|
-
if (gradleVersion.match(/Gradle 7/))
|
|
207459
|
+
if (gradleVersion.match(/Gradle 7/) || gradleVersion.match(/Gradle 8/))
|
|
207445
207460
|
args.push('--no-configuration-cache');
|
|
207446
207461
|
// There might be a legacy --configuration option in 'args'.
|
|
207447
207462
|
// It has been superseded by --configuration-matching option for Snyk CLI (see buildArgs),
|