Socket
Socket
Sign inDemoInstall

snyk-nuget-plugin

Package Overview
Dependencies
Maintainers
1
Versions
123
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

snyk-nuget-plugin - npm Package Compare versions

Comparing version 1.39.0 to 1.39.1

7

dist/nuget-parser/csharp/nugetframeworks_parser.js

@@ -13,7 +13,7 @@ "use strict";

<OutputType>Exe</OutputType>
<TargetFramework>net7.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<TargetFramework>net6.0</TargetFramework>
<Nullable>enable</Nullable>
<RootNamespace>ShortNameToLongName</RootNamespace>
<GenerateRuntimeConfigurationFiles>true</GenerateRuntimeConfigurationFiles>
<RollForward>LatestMajor</RollForward>
</PropertyGroup>

@@ -31,7 +31,6 @@

contents: `
using System;
using NuGet.Frameworks;
using Newtonsoft.Json;
namespace ShortNameToLongName;
class Program

@@ -38,0 +37,0 @@ {

@@ -8,2 +8,3 @@ "use strict";

const debugModule = require("debug");
const depsParser = require("dotnet-deps-parser");
const dotnetCoreParser = require("./parsers/dotnet-core-parser");

@@ -102,3 +103,3 @@ const dotnetCoreV2Parser = require("./parsers/dotnet-core-v2-parser");

}
if (!runtimeAssembly.isSupported(decidedTargetFramework)) {
if (!depsParser.isSupportedByV2GraphGeneration(decidedTargetFramework)) {
throw new errors_1.FileNotProcessableError(`runtime resolution flag is currently only supported for: .NET versions 5 and higher, all versions of .NET Core and all versions of .NET Standard projects. Supplied versions was parsed as: ${decidedTargetFramework}.`);

@@ -105,0 +106,0 @@ }

import { AssemblyVersions } from './types';
export declare function isSupported(targetFramework: string): boolean;
export declare function generateRuntimeAssemblies(filePath: string): AssemblyVersions;
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.generateRuntimeAssemblies = exports.isSupported = void 0;
exports.generateRuntimeAssemblies = void 0;
const errors = require("../errors/");

@@ -10,25 +10,2 @@ const fs = require("fs");

const debug = debugModule('snyk');
// At least to keep project development iterative, don't support needle and haystack'ing dependency JSON
// for target frameworks other than .NET 5+ and .NET Core, as other frameworks generates vastly other types of
// .json graphs, requiring a whole other parsing strategy to extract tne runtime dependencies.
// For a list of version naming currently available, see
// https://learn.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-frameworks
function isSupported(targetFramework) {
// Everything that does not start with 'net' is already game over. E.g. Windows Phone (wp) or silverlight (sl) etc.
if (!targetFramework.startsWith('net')) {
return false;
}
// What's left is:
// - .NET Core: netcoreappN.N,
// - .NET 5+ netN.N,
// - .NET Standard: netstandardN.N and
// - .NET Framework: netNNN, all of which we support except the latter.
// So if there's a dot, we're good.
if (targetFramework.includes('.')) {
return true;
}
// Otherwise it's something before .NET 5 and we're out
return false;
}
exports.isSupported = isSupported;
// The Nuget dependency resolution rule of lowest applicable version

@@ -35,0 +12,0 @@ // (see https://learn.microsoft.com/en-us/nuget/concepts/dependency-resolution#lowest-applicable-version)

@@ -42,3 +42,3 @@ {

"debug": "^4.3.4",
"dotnet-deps-parser": "5.3.0",
"dotnet-deps-parser": "5.5.1",
"jszip": "3.10.1",

@@ -62,3 +62,3 @@ "lodash": "^4.17.21",

},
"version": "1.39.0"
"version": "1.39.1"
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc