Coder Social home page Coder Social logo

sharonkoch / blogifier_demo Goto Github PK

View Code? Open in Web Editor NEW

This project forked from blogifierdotnet/blogifier

1.0 0.0 0.0 77.1 MB

Blogifier is an open-source publishing platform Written in ASP.NET and Blazor WebAssembly. With Blogifier make a personal blog or a website.

Home Page: https://blogifier.net

License: MIT License

Shell 0.06% JavaScript 6.24% C# 51.64% HTML 27.98% Batchfile 0.04% Dockerfile 0.12% SCSS 13.92%

blogifier_demo's Introduction


Blogifier

Blogifier is a self-hosted open source publishing platform written in ASP.NET and Blazor WebAssembly. It can be used to quickly and easily set up a lightweight, but fully functional personal or group blog.


English | 简体中文

Installation

Currently built from source [Not Released]

Can build in windows linux not tested on macOS, I prefer to deploy tests in docker.

native build

  1. Download .NET 7.0 SDK Choose to install the system version on your host. Download Nodejs 14 and above and install it on your host. For linux you can use the package management tool
  2. Navigate to the project root directory, run ./publish.cmd on the command line in widnows, run sh ./publish.sh on the command line in linux.
  3. When the command execution is complete and there are no errors, you will see the dist folder in the project root directory, which is the application after publishing. You can copy it to run anywhere. In windows, you can directly click to run the dist folder Blogifier.exe , in linux, please authorize the executable permission of the Blogifier binary file first and then click or run it on the command line. [note] Because the app_data directory does not exist in the release, an error may occur when the program starts. Just start it again.
  4. Then you can open localhost:5000 with your browser
  5. Done, enjoy.

docker build

First of all, please make sure that docker, docker-compose has been installed in your host.

  1. Navigate to the project root directory Run the docker-compose up -d command, wait a while ...
  2. Then you can open localhost:8080 with your browser
  3. Done, enjoy.

Versions before 3.0

Steps to install compiled application on the server for a self-hosting:

  1. .NET Core Runtime (currently 7.0) must be installed on your host server.
  2. Download the latest release.
  3. Unzip and copy to your host server.
  4. Restart your website.
  5. Open your website and only the first time you'll be redirected to the register page.
    example.com/admin/register/
  6. Register, and then log in.
    example.com/admin/login/
  7. Done, enjoy.

Development

If you want to customize the Blogifier, or contribute:

  1. Download and Install .NET SDK.
  2. Download and Install NodeJs.
  3. Download, fork, or clone the repository.
  4. Open the project with your favorite IDE (VS Code, Visual Studio, Atom, etc).
  5. Run the app with your IDE or these commands:
$ cd /your-local-path/Blogifier/src/Blogifier/
$ dotnet run

Then you can open localhost:5000 with your browser

Contributing

The current Blogifier is not perfect enough, blog software pursues perfect functions and easy to use, maybe wordpress is more suitable, relatively speaking, this project still lacks many functions. The latest version has not been released yet, and the current project is more suitable for developers to build and use by themselves. We can work together Improvement, implement a blog system completely implemented by dotnet technology. Faster, simpler, and smaller.

You can first propose functions in issues and develop them in pull requests, so that you can track the development progress. Everyone is welcome to participate in the development together. Let's learn and explore the latest technology of dotnet together.

Team

@dorthl   @farzindev   @rxtur

Copyright and License

Code released under the MIT License. Docs released under Creative Commons.
Copyright 2017–2023 Blogifier

blogifier_demo's People

Contributors

rxtur avatar farzindev avatar dorthl avatar sharonkoch avatar alexandrudanpop avatar fullreboot avatar pablotdv avatar jwmxyz avatar anotherice avatar nickgraham101 avatar rdalkire avatar hez2010 avatar shps951023 avatar findersky avatar dependabot[bot] avatar mikeanuta avatar takerman avatar ismaelmiah avatar wangfu91 avatar dansiegel avatar burmistrov-tech avatar mend-for-github-com[bot] avatar azure-pipelines[bot] avatar amironline avatar amira133 avatar walidaslam7 avatar samuelsoderberg avatar rodumv avatar peim8 avatar marcelo-maciel avatar

Stargazers

 avatar

blogifier_demo's Issues

Blogifier-1.0.0: 7 vulnerabilities (highest severity is: 8.8)

Vulnerable Library - Blogifier-1.0.0

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/azure.identity/1.6.0/azure.identity.1.6.0.nupkg

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Vulnerabilities

CVE Severity CVSS Dependency Type Fixed in (Blogifier version) Remediation Possible**
CVE-2023-36414 High 8.8 azure.identity.1.6.0.nupkg Transitive N/A*
CVE-2024-0056 High 8.7 microsoft.data.sqlclient.5.0.2.nupkg Transitive N/A*
CVE-2021-24112 High 8.1 system.drawing.common.5.0.0.nupkg Transitive N/A*
CVE-2023-29331 High 7.5 system.security.cryptography.pkcs.7.0.0.nupkg Transitive N/A*
CVE-2024-21319 Medium 6.8 detected in multiple dependencies Transitive N/A*
CVE-2024-35255 Medium 5.5 azure.identity.1.6.0.nupkg Transitive N/A*
CVE-2024-29992 Medium 5.5 azure.identity.1.6.0.nupkg Transitive N/A*

*For some transitive vulnerabilities, there is no version of direct dependency with a fix. Check the "Details" section below to see if there is a version of transitive dependency where vulnerability is fixed.

**In some cases, Remediation PR cannot be created automatically for a vulnerability despite the availability of remediation

Details

CVE-2023-36414

Vulnerable Library - azure.identity.1.6.0.nupkg

This is the implementation of the Azure SDK Client Library for Azure Identity

Library home page: https://api.nuget.org/packages/azure.identity.1.6.0.nupkg

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/azure.identity/1.6.0/azure.identity.1.6.0.nupkg

Dependency Hierarchy:

  • Blogifier-1.0.0 (Root Library)
    • microsoft.entityframeworkcore.sqlserver.7.0.10.nupkg
      • microsoft.data.sqlclient.5.0.2.nupkg
        • azure.identity.1.6.0.nupkg (Vulnerable Library)

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Found in base branch: main

Vulnerability Details

Azure Identity SDK Remote Code Execution Vulnerability

Publish Date: 2023-10-10

URL: CVE-2023-36414

CVSS 3 Score Details (8.8)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Network
    • Attack Complexity: Low
    • Privileges Required: Low
    • User Interaction: None
    • Scope: Unchanged
  • Impact Metrics:
    • Confidentiality Impact: High
    • Integrity Impact: High
    • Availability Impact: High

For more information on CVSS3 Scores, click here.

Suggested Fix

Type: Upgrade version

Origin: https://nvd.nist.gov/vuln/detail/CVE-2023-36414

Release Date: 2023-10-10

Fix Resolution: Azure.Identity - 1.10.2

CVE-2024-0056

Vulnerable Library - microsoft.data.sqlclient.5.0.2.nupkg

Provides the data provider for SQL Server.

Library home page: https://api.nuget.org/packages/microsoft.data.sqlclient.5.0.2.nupkg

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/microsoft.data.sqlclient/5.0.2/microsoft.data.sqlclient.5.0.2.nupkg

Dependency Hierarchy:

  • Blogifier-1.0.0 (Root Library)
    • microsoft.entityframeworkcore.sqlserver.7.0.10.nupkg
      • microsoft.data.sqlclient.5.0.2.nupkg (Vulnerable Library)

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Found in base branch: main

Vulnerability Details

Microsoft.Data.SqlClient and System.Data.SqlClient SQL Data Provider Security Feature Bypass Vulnerability

Publish Date: 2024-01-09

URL: CVE-2024-0056

CVSS 3 Score Details (8.7)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Network
    • Attack Complexity: High
    • Privileges Required: None
    • User Interaction: None
    • Scope: Changed
  • Impact Metrics:
    • Confidentiality Impact: High
    • Integrity Impact: High
    • Availability Impact: None

For more information on CVSS3 Scores, click here.

Suggested Fix

Type: Upgrade version

Origin: GHSA-98g6-xh36-x2p7

Release Date: 2024-01-09

Fix Resolution: Microsoft.Data.SqlClient - 2.1.7,3.1.5,4.0.5,5.1.3, System.Data.SqlClient - 4.8.6

CVE-2021-24112

Vulnerable Library - system.drawing.common.5.0.0.nupkg

Provides access to GDI+ graphics functionality.

Commonly Used Types:
System.Drawing.Bitmap
System.D...

Library home page: https://api.nuget.org/packages/system.drawing.common.5.0.0.nupkg

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/system.drawing.common/5.0.0/system.drawing.common.5.0.0.nupkg

Dependency Hierarchy:

  • Blogifier-1.0.0 (Root Library)
    • microsoft.entityframeworkcore.sqlserver.7.0.10.nupkg
      • microsoft.data.sqlclient.5.0.2.nupkg
        • system.runtime.caching.5.0.0.nupkg
          • system.configuration.configurationmanager.5.0.0.nupkg
            • system.security.permissions.5.0.0.nupkg
              • system.windows.extensions.5.0.0.nupkg
                • system.drawing.common.5.0.0.nupkg (Vulnerable Library)

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Found in base branch: main

Vulnerability Details

.NET Core Remote Code Execution Vulnerability

Publish Date: 2021-02-25

URL: CVE-2021-24112

CVSS 3 Score Details (8.1)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Network
    • Attack Complexity: High
    • Privileges Required: None
    • User Interaction: None
    • Scope: Unchanged
  • Impact Metrics:
    • Confidentiality Impact: High
    • Integrity Impact: High
    • Availability Impact: High

For more information on CVSS3 Scores, click here.

Suggested Fix

Type: Upgrade version

Origin: GHSA-rxg9-xrhp-64gj

Release Date: 2021-02-25

Fix Resolution: System.Drawing.Common - 4.7.2,5.0.3

CVE-2023-29331

Vulnerable Library - system.security.cryptography.pkcs.7.0.0.nupkg

Provides support for PKCS and CMS algorithms.

Commonly Used Types:
System.Security.Cryptography.Pkcs.EnvelopedCms

Library home page: https://api.nuget.org/packages/system.security.cryptography.pkcs.7.0.0.nupkg

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/system.security.cryptography.pkcs/7.0.0/system.security.cryptography.pkcs.7.0.0.nupkg

Dependency Hierarchy:

  • Blogifier-1.0.0 (Root Library)
    • microsoft.aspnetcore.dataprotection.stackexchangeredis.7.0.10.nupkg
      • microsoft.aspnetcore.dataprotection.7.0.10.nupkg
        • system.security.cryptography.xml.7.0.1.nupkg
          • system.security.cryptography.pkcs.7.0.0.nupkg (Vulnerable Library)

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Found in base branch: main

Vulnerability Details

.NET, .NET Framework, and Visual Studio Denial of Service Vulnerability

Publish Date: 2023-06-14

URL: CVE-2023-29331

CVSS 3 Score Details (7.5)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Network
    • Attack Complexity: Low
    • Privileges Required: None
    • User Interaction: None
    • Scope: Unchanged
  • Impact Metrics:
    • Confidentiality Impact: None
    • Integrity Impact: None
    • Availability Impact: High

For more information on CVSS3 Scores, click here.

Suggested Fix

Type: Upgrade version

Origin: GHSA-555c-2p6r-68mm

Release Date: 2023-06-14

Fix Resolution: Microsoft.NetCore.App.Runtime.linux-arm - 6.0.18,7.0.7, Microsoft.Windows.Compatibility - 6.0.6,7.0.3, System.Security.Cryptography.Pkcs - 6.0.3,7.0.2

CVE-2024-21319

Vulnerable Libraries - microsoft.identitymodel.jsonwebtokens.6.21.0.nupkg, system.identitymodel.tokens.jwt.6.21.0.nupkg

microsoft.identitymodel.jsonwebtokens.6.21.0.nupkg

Includes types that provide support for creating, serializing and validating JSON Web Tokens.

Library home page: https://api.nuget.org/packages/microsoft.identitymodel.jsonwebtokens.6.21.0.nupkg

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/microsoft.identitymodel.jsonwebtokens/6.21.0/microsoft.identitymodel.jsonwebtokens.6.21.0.nupkg

Dependency Hierarchy:

  • Blogifier-1.0.0 (Root Library)
    • microsoft.entityframeworkcore.sqlserver.7.0.10.nupkg
      • microsoft.data.sqlclient.5.0.2.nupkg
        • microsoft.identitymodel.jsonwebtokens.6.21.0.nupkg (Vulnerable Library)

system.identitymodel.tokens.jwt.6.21.0.nupkg

Includes types that provide support for creating, serializing and validating JSON Web Tokens.

Library home page: https://api.nuget.org/packages/system.identitymodel.tokens.jwt.6.21.0.nupkg

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/system.identitymodel.tokens.jwt/6.21.0/system.identitymodel.tokens.jwt.6.21.0.nupkg

Dependency Hierarchy:

  • Blogifier-1.0.0 (Root Library)
    • microsoft.entityframeworkcore.sqlserver.7.0.10.nupkg
      • microsoft.data.sqlclient.5.0.2.nupkg
        • microsoft.identitymodel.protocols.openidconnect.6.21.0.nupkg
          • system.identitymodel.tokens.jwt.6.21.0.nupkg (Vulnerable Library)

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Found in base branch: main

Vulnerability Details

Microsoft Identity Denial of service vulnerability

Publish Date: 2024-01-09

URL: CVE-2024-21319

CVSS 3 Score Details (6.8)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Network
    • Attack Complexity: Low
    • Privileges Required: High
    • User Interaction: None
    • Scope: Changed
  • Impact Metrics:
    • Confidentiality Impact: None
    • Integrity Impact: None
    • Availability Impact: High

For more information on CVSS3 Scores, click here.

Suggested Fix

Type: Upgrade version

Origin: GHSA-8g9c-28fc-mcx2

Release Date: 2024-01-09

Fix Resolution: System.IdentityModel.Tokens.Jwt - 5.7.0,6.34.0,7.1.2, Microsoft.IdentityModel.JsonWebTokens - 5.7.0,6.34.0,7.1.2

CVE-2024-35255

Vulnerable Library - azure.identity.1.6.0.nupkg

This is the implementation of the Azure SDK Client Library for Azure Identity

Library home page: https://api.nuget.org/packages/azure.identity.1.6.0.nupkg

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/azure.identity/1.6.0/azure.identity.1.6.0.nupkg

Dependency Hierarchy:

  • Blogifier-1.0.0 (Root Library)
    • microsoft.entityframeworkcore.sqlserver.7.0.10.nupkg
      • microsoft.data.sqlclient.5.0.2.nupkg
        • azure.identity.1.6.0.nupkg (Vulnerable Library)

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Found in base branch: main

Vulnerability Details

Azure Identity Libraries and Microsoft Authentication Library Elevation of Privilege Vulnerability

Publish Date: 2024-06-11

URL: CVE-2024-35255

CVSS 3 Score Details (5.5)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Local
    • Attack Complexity: Low
    • Privileges Required: Low
    • User Interaction: None
    • Scope: Unchanged
  • Impact Metrics:
    • Confidentiality Impact: High
    • Integrity Impact: None
    • Availability Impact: None

For more information on CVSS3 Scores, click here.

Suggested Fix

Type: Upgrade version

Origin: GHSA-m5vv-6r4h-3vj9

Release Date: 2024-06-11

Fix Resolution: @azure/identity - 4.2.1, @azure/msal-node - 2.9.1, Azure.Identity - 1.11.4, Microsoft.Identity.Client - 4.61.3, azure-identity - 1.16.1, com.azure:azure-identity:1.12.2, github.com/Azure/azure-sdk-for-go/sdk/azidentity - 1.6.0

CVE-2024-29992

Vulnerable Library - azure.identity.1.6.0.nupkg

This is the implementation of the Azure SDK Client Library for Azure Identity

Library home page: https://api.nuget.org/packages/azure.identity.1.6.0.nupkg

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/azure.identity/1.6.0/azure.identity.1.6.0.nupkg

Dependency Hierarchy:

  • Blogifier-1.0.0 (Root Library)
    • microsoft.entityframeworkcore.sqlserver.7.0.10.nupkg
      • microsoft.data.sqlclient.5.0.2.nupkg
        • azure.identity.1.6.0.nupkg (Vulnerable Library)

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Found in base branch: main

Vulnerability Details

Azure Identity Library for .NET Information Disclosure Vulnerability

Publish Date: 2024-04-09

URL: CVE-2024-29992

CVSS 3 Score Details (5.5)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Local
    • Attack Complexity: Low
    • Privileges Required: Low
    • User Interaction: None
    • Scope: Unchanged
  • Impact Metrics:
    • Confidentiality Impact: High
    • Integrity Impact: None
    • Availability Impact: None

For more information on CVSS3 Scores, click here.

Suggested Fix

Type: Upgrade version

Origin: GHSA-wvxc-855f-jvrv

Release Date: 2024-04-09

Fix Resolution: Azure.Identity - 1.11.0

sotsera.blazor.toaster.3.0.0.nupkg: 1 vulnerabilities (highest severity is: 6.2)

Vulnerable Library - sotsera.blazor.toaster.3.0.0.nupkg

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/microsoft.aspnetcore.components/7.0.10/microsoft.aspnetcore.components.7.0.10.nupkg

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Vulnerabilities

CVE Severity CVSS Dependency Type Fixed in (sotsera.blazor.toaster.3.0.0.nupkg version) Remediation Possible**
CVE-2023-36558 Medium 6.2 microsoft.aspnetcore.components.7.0.10.nupkg Transitive N/A*

*For some transitive vulnerabilities, there is no version of direct dependency with a fix. Check the "Details" section below to see if there is a version of transitive dependency where vulnerability is fixed.

**In some cases, Remediation PR cannot be created automatically for a vulnerability despite the availability of remediation

Details

CVE-2023-36558

Vulnerable Library - microsoft.aspnetcore.components.7.0.10.nupkg

Components feature for ASP.NET Core.

This package was built from the source code at https://github.com/dotnet/aspnetcore/tree/5a4c82ec57fadddef9ce841d608de5c7c8c74446

Library home page: https://api.nuget.org/packages/microsoft.aspnetcore.components.7.0.10.nupkg

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/microsoft.aspnetcore.components/7.0.10/microsoft.aspnetcore.components.7.0.10.nupkg

Dependency Hierarchy:

  • sotsera.blazor.toaster.3.0.0.nupkg (Root Library)
    • microsoft.aspnetcore.components.7.0.10.nupkg (Vulnerable Library)

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Found in base branch: main

Vulnerability Details

ASP.NET Core - Security Feature Bypass Vulnerability

Publish Date: 2023-11-14

URL: CVE-2023-36558

CVSS 3 Score Details (6.2)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Local
    • Attack Complexity: Low
    • Privileges Required: None
    • User Interaction: None
    • Scope: Unchanged
  • Impact Metrics:
    • Confidentiality Impact: High
    • Integrity Impact: None
    • Availability Impact: None

For more information on CVSS3 Scores, click here.

Suggested Fix

Type: Upgrade version

Origin: GHSA-3fx3-85r4-8j3w

Release Date: 2023-11-14

Fix Resolution: Microsoft.AspNetCore.Components - 6.0.25,7.0.14,8.0.0

Code Security Report: 9 high severity findings, 20 total findings

Code Security Report

Scan Metadata

Latest Scan: 2024-07-30 05:13am
Total Findings: 20 | New Findings: 7 | Resolved Findings: 5
Tested Project Files: 250
Detected Programming Languages: 2 (JavaScript / TypeScript*, C#*)

  • Check this box to manually trigger a scan

Most Relevant Findings

The list below presents the 10 most relevant findings that need your attention. To view information on the remaining findings, navigate to the Mend Application.

SeverityVulnerability TypeCWEFileData FlowsDate
HighPath/Directory Traversal

CWE-22

StorageLocalProvider.cs:132

22024-07-30 05:13am
Vulnerable Code

private async Task<string> WriteAsync(string path, byte[] bytes)
{
var storagePath = Path.Combine(_pathLocalRoot, path);
var directoryPath = Path.GetDirectoryName(storagePath)!;
if (!Directory.Exists(directoryPath)) Directory.CreateDirectory(directoryPath);

2 Data Flow/s detected
View Data Flow 1

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public string? Cover { get; set; }

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public async Task<string> UploadImagesBase64(DateTime uploadAt, int userid, string dataOrUrl)

View remaining steps

Slug = await WriteAsync(path, bytes),

private async Task<string> WriteAsync(string path, byte[] bytes)

var storagePath = Path.Combine(_pathLocalRoot, path);

var directoryPath = Path.GetDirectoryName(storagePath)!;

if (!Directory.Exists(directoryPath)) Directory.CreateDirectory(directoryPath);

View Data Flow 2

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public string? Cover { get; set; }

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public async Task<string> UploadImagesBase64(DateTime uploadAt, int userid, string dataOrUrl)

View remaining steps

Slug = await WriteAsync(path, bytes),

private async Task<string> WriteAsync(string path, byte[] bytes)

var storagePath = Path.Combine(_pathLocalRoot, path);

var directoryPath = Path.GetDirectoryName(storagePath)!;

if (!Directory.Exists(directoryPath)) Directory.CreateDirectory(directoryPath);

Secure Code Warrior Training Material

● Training

   ▪ Secure Code Warrior Path/Directory Traversal Training

● Videos

   ▪ Secure Code Warrior Path/Directory Traversal Video

● Further Reading

   ▪ OWASP Path Traversal

   ▪ OWASP Input Validation Cheat Sheet

 
HighPath/Directory Traversal

CWE-22

StorageLocalProvider.cs:133

22024-07-30 05:13am
Vulnerable Code

private async Task<string> WriteAsync(string path, byte[] bytes)
{
var storagePath = Path.Combine(_pathLocalRoot, path);
var directoryPath = Path.GetDirectoryName(storagePath)!;
if (!Directory.Exists(directoryPath)) Directory.CreateDirectory(directoryPath);
await File.WriteAllBytesAsync(storagePath, bytes);

2 Data Flow/s detected
View Data Flow 1

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public string? Cover { get; set; }

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public async Task<string> UploadImagesBase64(DateTime uploadAt, int userid, string dataOrUrl)

View remaining steps

Slug = await WriteAsync(path, bytes),

private async Task<string> WriteAsync(string path, byte[] bytes)

var storagePath = Path.Combine(_pathLocalRoot, path);

var directoryPath = Path.GetDirectoryName(storagePath)!;

await File.WriteAllBytesAsync(storagePath, bytes);

View Data Flow 2

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public string? Cover { get; set; }

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public async Task<string> UploadImagesBase64(DateTime uploadAt, int userid, string dataOrUrl)

View remaining steps

Slug = await WriteAsync(path, bytes),

private async Task<string> WriteAsync(string path, byte[] bytes)

var storagePath = Path.Combine(_pathLocalRoot, path);

var directoryPath = Path.GetDirectoryName(storagePath)!;

await File.WriteAllBytesAsync(storagePath, bytes);

Secure Code Warrior Training Material

● Training

   ▪ Secure Code Warrior Path/Directory Traversal Training

● Videos

   ▪ Secure Code Warrior Path/Directory Traversal Video

● Further Reading

   ▪ OWASP Path Traversal

   ▪ OWASP Input Validation Cheat Sheet

 
HighPath/Directory Traversal

CWE-22

StorageLocalProvider.cs:132

22024-07-30 05:13am
Vulnerable Code

private async Task<string> WriteAsync(string path, byte[] bytes)
{
var storagePath = Path.Combine(_pathLocalRoot, path);
var directoryPath = Path.GetDirectoryName(storagePath)!;
if (!Directory.Exists(directoryPath)) Directory.CreateDirectory(directoryPath);

2 Data Flow/s detected
View Data Flow 1

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public string? Cover { get; set; }

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public async Task<string> UploadImagesBase64(DateTime uploadAt, int userid, string dataOrUrl)

View remaining steps

Slug = await WriteAsync(path, bytes),

private async Task<string> WriteAsync(string path, byte[] bytes)

var storagePath = Path.Combine(_pathLocalRoot, path);

var directoryPath = Path.GetDirectoryName(storagePath)!;

if (!Directory.Exists(directoryPath)) Directory.CreateDirectory(directoryPath);

View Data Flow 2

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public string? Cover { get; set; }

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public async Task<string> UploadImagesBase64(DateTime uploadAt, int userid, string dataOrUrl)

View remaining steps

Slug = await WriteAsync(path, bytes),

private async Task<string> WriteAsync(string path, byte[] bytes)

var storagePath = Path.Combine(_pathLocalRoot, path);

var directoryPath = Path.GetDirectoryName(storagePath)!;

if (!Directory.Exists(directoryPath)) Directory.CreateDirectory(directoryPath);

Secure Code Warrior Training Material

● Training

   ▪ Secure Code Warrior Path/Directory Traversal Training

● Videos

   ▪ Secure Code Warrior Path/Directory Traversal Video

● Further Reading

   ▪ OWASP Path Traversal

   ▪ OWASP Input Validation Cheat Sheet

 
HighServer Side Request Forgery

CWE-918

StorageManager.cs:50

22024-05-20 02:28pm
Vulnerable Code

public async Task<StorageDto> UploadAsync(DateTime uploadAt, int userid, Uri baseAddress, string url, string? fileName = null)
{
using var client = _httpClientFactory.CreateClient();
client.BaseAddress = baseAddress;
using var response = await client.GetAsync(url);

2 Data Flow/s detected
View Data Flow 1

using var response = await client.GetAsync(url);

View Data Flow 2

return await _importManager.WriteAsync(request, userId);

public async Task<IEnumerable<PostEditorDto>> WriteAsync(ImportDto request, int userId)

foreach (var post in request.Posts)

public new List<FrontPostImportDto> Posts { get; set; } = default!;

foreach (var post in request.Posts)

await _storageManager.UploadAsync(publishedAt, user.Id, baseAddress, post.Cover);

public async Task<StorageDto> UploadAsync(DateTime uploadAt, int userid, Uri baseAddress, string url, string? fileName = null)

using var response = await client.GetAsync(url);

Secure Code Warrior Training Material

● Training

   ▪ Secure Code Warrior Server Side Request Forgery Training

● Videos

   ▪ Secure Code Warrior Server Side Request Forgery Video

 
HighPath/Directory Traversal

CWE-22

StorageLocalProvider.cs:120

42024-05-20 02:28pm
Vulnerable Code

private async Task<string> WriteAsync(string path, Stream stream)
{
var storagePath = Path.Combine(_pathLocalRoot, path);
var directoryPath = Path.GetDirectoryName(storagePath)!;
if (!Directory.Exists(directoryPath)) Directory.CreateDirectory(directoryPath);
using var fileStream = new FileStream(storagePath, FileMode.CreateNew);

4 Data Flow/s detected
View Data Flow 1

using var response = await client.GetAsync(url);

fileName = response.Content.Headers.ContentDisposition?.FileNameStar;

path = $"{folder}/{fileName}";

var storage = await _storageProvider.GetCheckStoragAsync(path);

public async Task<StorageDto?> GetCheckStoragAsync(string path)

View remaining steps

Slug = await WriteAsync(path, stream),

private async Task<string> WriteAsync(string path, Stream stream)

var storagePath = Path.Combine(_pathLocalRoot, path);

var directoryPath = Path.GetDirectoryName(storagePath)!;

using var fileStream = new FileStream(storagePath, FileMode.CreateNew);

View Data Flow 2

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public string? Cover { get; set; }

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public async Task<string> UploadImagesBase64(DateTime uploadAt, int userid, string dataOrUrl)

View remaining steps

public async Task<StorageDto> AddAsync(DateTime uploadAt, int userid, string path, string fileName, Stream stream, string contentType)

Slug = await WriteAsync(path, stream),

private async Task<string> WriteAsync(string path, Stream stream)

var storagePath = Path.Combine(_pathLocalRoot, path);

using var fileStream = new FileStream(storagePath, FileMode.CreateNew);

View Data Flow 3

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public string? Cover { get; set; }

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public async Task<string> UploadImagesBase64(DateTime uploadAt, int userid, string dataOrUrl)

View remaining steps

public async Task<StorageDto> AddAsync(DateTime uploadAt, int userid, string path, string fileName, Stream stream, string contentType)

Slug = await WriteAsync(path, stream),

private async Task<string> WriteAsync(string path, Stream stream)

var storagePath = Path.Combine(_pathLocalRoot, path);

using var fileStream = new FileStream(storagePath, FileMode.CreateNew);

View more Data Flows

Secure Code Warrior Training Material

● Training

   ▪ Secure Code Warrior Path/Directory Traversal Training

● Videos

   ▪ Secure Code Warrior Path/Directory Traversal Video

● Further Reading

   ▪ OWASP Path Traversal

   ▪ OWASP Input Validation Cheat Sheet

 
HighPath/Directory Traversal

CWE-22

StorageLocalProvider.cs:119

42024-05-20 02:28pm
Vulnerable Code

private async Task<string> WriteAsync(string path, Stream stream)
{
var storagePath = Path.Combine(_pathLocalRoot, path);
var directoryPath = Path.GetDirectoryName(storagePath)!;
if (!Directory.Exists(directoryPath)) Directory.CreateDirectory(directoryPath);

4 Data Flow/s detected
View Data Flow 1

using var response = await client.GetAsync(url);

fileName = response.Content.Headers.ContentDisposition?.FileNameStar;

path = $"{folder}/{fileName}";

var storage = await _storageProvider.GetCheckStoragAsync(path);

public async Task<StorageDto?> GetCheckStoragAsync(string path)

View remaining steps

Slug = await WriteAsync(path, stream),

private async Task<string> WriteAsync(string path, Stream stream)

var storagePath = Path.Combine(_pathLocalRoot, path);

var directoryPath = Path.GetDirectoryName(storagePath)!;

if (!Directory.Exists(directoryPath)) Directory.CreateDirectory(directoryPath);

View Data Flow 2

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public string? Cover { get; set; }

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public async Task<string> UploadImagesBase64(DateTime uploadAt, int userid, string dataOrUrl)

View remaining steps

Slug = await WriteAsync(path, stream),

private async Task<string> WriteAsync(string path, Stream stream)

var storagePath = Path.Combine(_pathLocalRoot, path);

var directoryPath = Path.GetDirectoryName(storagePath)!;

if (!Directory.Exists(directoryPath)) Directory.CreateDirectory(directoryPath);

View Data Flow 3

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public string? Cover { get; set; }

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public async Task<string> UploadImagesBase64(DateTime uploadAt, int userid, string dataOrUrl)

View remaining steps

Slug = await WriteAsync(path, stream),

private async Task<string> WriteAsync(string path, Stream stream)

var storagePath = Path.Combine(_pathLocalRoot, path);

var directoryPath = Path.GetDirectoryName(storagePath)!;

if (!Directory.Exists(directoryPath)) Directory.CreateDirectory(directoryPath);

View more Data Flows

Secure Code Warrior Training Material

● Training

   ▪ Secure Code Warrior Path/Directory Traversal Training

● Videos

   ▪ Secure Code Warrior Path/Directory Traversal Video

● Further Reading

   ▪ OWASP Path Traversal

   ▪ OWASP Input Validation Cheat Sheet

 
HighPath/Directory Traversal

CWE-22

StorageLocalProvider.cs:119

42024-05-20 02:28pm
Vulnerable Code

private async Task<string> WriteAsync(string path, Stream stream)
{
var storagePath = Path.Combine(_pathLocalRoot, path);
var directoryPath = Path.GetDirectoryName(storagePath)!;
if (!Directory.Exists(directoryPath)) Directory.CreateDirectory(directoryPath);

4 Data Flow/s detected
View Data Flow 1

using var response = await client.GetAsync(url);

fileName = response.Content.Headers.ContentDisposition?.FileNameStar;

path = $"{folder}/{fileName}";

var storage = await _storageProvider.GetCheckStoragAsync(path);

public async Task<StorageDto?> GetCheckStoragAsync(string path)

View remaining steps

Slug = await WriteAsync(path, stream),

private async Task<string> WriteAsync(string path, Stream stream)

var storagePath = Path.Combine(_pathLocalRoot, path);

var directoryPath = Path.GetDirectoryName(storagePath)!;

if (!Directory.Exists(directoryPath)) Directory.CreateDirectory(directoryPath);

View Data Flow 2

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public string? Cover { get; set; }

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public async Task<string> UploadImagesBase64(DateTime uploadAt, int userid, string dataOrUrl)

View remaining steps

Slug = await WriteAsync(path, stream),

private async Task<string> WriteAsync(string path, Stream stream)

var storagePath = Path.Combine(_pathLocalRoot, path);

var directoryPath = Path.GetDirectoryName(storagePath)!;

if (!Directory.Exists(directoryPath)) Directory.CreateDirectory(directoryPath);

View Data Flow 3

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public string? Cover { get; set; }

var coverUrl = await storageManager.UploadImagesBase64(uploadAt, userId, post.Cover);

public async Task<string> UploadImagesBase64(DateTime uploadAt, int userid, string dataOrUrl)

View remaining steps

Slug = await WriteAsync(path, stream),

private async Task<string> WriteAsync(string path, Stream stream)

var storagePath = Path.Combine(_pathLocalRoot, path);

var directoryPath = Path.GetDirectoryName(storagePath)!;

if (!Directory.Exists(directoryPath)) Directory.CreateDirectory(directoryPath);

View more Data Flows

Secure Code Warrior Training Material

● Training

   ▪ Secure Code Warrior Path/Directory Traversal Training

● Videos

   ▪ Secure Code Warrior Path/Directory Traversal Video

● Further Reading

   ▪ OWASP Path Traversal

   ▪ OWASP Input Validation Cheat Sheet

 
HighPath/Directory Traversal

CWE-22

StorageLocalProvider.cs:105

22024-05-20 02:28pm
Vulnerable Code

private void Delete(string path)
{
var storagePath = Path.Combine(_pathLocalRoot, path);
_logger.LogInformation("file delete: {storagePath}", storagePath);
File.Delete(storagePath);

2 Data Flow/s detected
View Data Flow 1

using var response = await client.GetAsync(url);

fileName = response.Content.Headers.ContentDisposition?.FileNameStar;

path = $"{folder}/{fileName}";

var storage = await _storageProvider.GetCheckStoragAsync(path);

public async Task<StorageDto?> GetCheckStoragAsync(string path)

View remaining steps

private void Delete(string path)

var storagePath = Path.Combine(_pathLocalRoot, path);

View Data Flow 2

return await _storageManager.UploadAsync(currTime, userId, file);

public async Task<StorageDto?> UploadAsync(DateTime uploadAt, int userid, IFormFile file)

var fileName = GetFileName(file.FileName);

private static string GetFileName(string fileName)

View remaining steps

private void Delete(string path)

var storagePath = Path.Combine(_pathLocalRoot, path);

Secure Code Warrior Training Material

● Training

   ▪ Secure Code Warrior Path/Directory Traversal Training

● Videos

   ▪ Secure Code Warrior Path/Directory Traversal Video

● Further Reading

   ▪ OWASP Path Traversal

   ▪ OWASP Input Validation Cheat Sheet

 
HighPath/Directory Traversal

CWE-22

StorageLocalProvider.cs:112

22024-05-20 02:28pm
Vulnerable Code

private bool Exists(string path)
{
var storagePath = Path.Combine(_pathLocalRoot, path);
_logger.LogInformation("file exists: {storagePath}", storagePath);
return File.Exists(storagePath);

2 Data Flow/s detected
View Data Flow 1

using var response = await client.GetAsync(url);

fileName = response.Content.Headers.ContentDisposition?.FileNameStar;

path = $"{folder}/{fileName}";

var storage = await _storageProvider.GetCheckStoragAsync(path);

public async Task<StorageDto?> GetCheckStoragAsync(string path)

private bool Exists(string path)

var storagePath = Path.Combine(_pathLocalRoot, path);

return File.Exists(storagePath);

View Data Flow 2

return await _storageManager.UploadAsync(currTime, userId, file);

public async Task<StorageDto?> UploadAsync(DateTime uploadAt, int userid, IFormFile file)

var fileName = GetFileName(file.FileName);

private static string GetFileName(string fileName)

View remaining steps

public async Task<StorageDto?> GetCheckStoragAsync(string path)

private bool Exists(string path)

var storagePath = Path.Combine(_pathLocalRoot, path);

return File.Exists(storagePath);

Secure Code Warrior Training Material

● Training

   ▪ Secure Code Warrior Path/Directory Traversal Training

● Videos

   ▪ Secure Code Warrior Path/Directory Traversal Video

● Further Reading

   ▪ OWASP Path Traversal

   ▪ OWASP Input Validation Cheat Sheet

 
MediumInsufficient Transport Layer Protection

CWE-319

EmailManager.cs:137

12024-05-20 02:28pm
Vulnerable Code

{
var client = new SmtpClient
{
ServerCertificateValidationCallback = (s, c, h, e) => true
};
client.Connect(settings.Host, settings.Port, SecureSocketOptions.Auto);

1 Data Flow/s detected

var client = new SmtpClient

Secure Code Warrior Training Material

● Training

   ▪ Secure Code Warrior Insufficient Transport Layer Protection Training

● Videos

   ▪ Secure Code Warrior Insufficient Transport Layer Protection Video

Findings Overview

Severity Vulnerability Type CWE Language Count
High Path/Directory Traversal CWE-22 C#* 8
High Server Side Request Forgery CWE-918 C#* 1
Medium Regex Denial of Service (ReDoS) CWE-1333 C#* 2
Medium Insufficient Transport Layer Protection CWE-319 C#* 1
Low Unvalidated/Open Redirect CWE-601 C#* 1
Low Log Forging CWE-117 C#* 7

microsoft.entityframeworkcore.design.7.0.10.nupkg: 1 vulnerabilities (highest severity is: 7.5)

Vulnerable Library - microsoft.entityframeworkcore.design.7.0.10.nupkg

Path to dependency file: /src/Blogifier/Blogifier.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/system.text.json/7.0.0/system.text.json.7.0.0.nupkg

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Vulnerabilities

CVE Severity CVSS Dependency Type Fixed in (microsoft.entityframeworkcore.design.7.0.10.nupkg version) Remediation Possible**
CVE-2024-30105 High 7.5 system.text.json.7.0.0.nupkg Transitive N/A*

*For some transitive vulnerabilities, there is no version of direct dependency with a fix. Check the "Details" section below to see if there is a version of transitive dependency where vulnerability is fixed.

**In some cases, Remediation PR cannot be created automatically for a vulnerability despite the availability of remediation

Details

CVE-2024-30105

Vulnerable Library - system.text.json.7.0.0.nupkg

Provides high-performance and low-allocating types that serialize objects to JavaScript Object Notation (JSON) text and deserialize JSON text to objects, with UTF-8 support built-in.

Library home page: https://api.nuget.org/packages/system.text.json.7.0.0.nupkg

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/system.text.json/7.0.0/system.text.json.7.0.0.nupkg

Dependency Hierarchy:

  • microsoft.entityframeworkcore.design.7.0.10.nupkg (Root Library)
    • microsoft.extensions.dependencymodel.7.0.0.nupkg
      • system.text.json.7.0.0.nupkg (Vulnerable Library)

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Found in base branch: main

Vulnerability Details

.NET Core and Visual Studio Denial of Service Vulnerability

Publish Date: 2024-07-09

URL: CVE-2024-30105

CVSS 3 Score Details (7.5)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Network
    • Attack Complexity: Low
    • Privileges Required: None
    • User Interaction: None
    • Scope: Unchanged
  • Impact Metrics:
    • Confidentiality Impact: None
    • Integrity Impact: None
    • Availability Impact: High

For more information on CVSS3 Scores, click here.

Suggested Fix

Type: Upgrade version

Origin: GHSA-hh2w-p6rv-4g7w

Release Date: 2024-07-09

Fix Resolution: System.Text.Json - 8.0.4

coverlet.collector.6.0.0.nupkg: 1 vulnerabilities (highest severity is: 7.5)

Vulnerable Library - coverlet.collector.6.0.0.nupkg

Coverlet is a cross platform code coverage library for .NET, with support for line, branch and method coverage.

Library home page: https://api.nuget.org/packages/coverlet.collector.6.0.0.nupkg

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/coverlet.collector/6.0.0/coverlet.collector.6.0.0.nupkg

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Vulnerabilities

CVE Severity CVSS Dependency Type Fixed in (coverlet.collector.6.0.0.nupkg version) Remediation Possible**
CVE-2024-21907 High 7.5 coverlet.collector.6.0.0.nupkg Direct Newtonsoft.Json - 13.0.1

**In some cases, Remediation PR cannot be created automatically for a vulnerability despite the availability of remediation

Details

CVE-2024-21907

Vulnerable Library - coverlet.collector.6.0.0.nupkg

Coverlet is a cross platform code coverage library for .NET, with support for line, branch and method coverage.

Library home page: https://api.nuget.org/packages/coverlet.collector.6.0.0.nupkg

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/coverlet.collector/6.0.0/coverlet.collector.6.0.0.nupkg

Dependency Hierarchy:

  • coverlet.collector.6.0.0.nupkg (Vulnerable Library)

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Found in base branch: main

Vulnerability Details

Newtonsoft.Json before version 13.0.1 is affected by a mishandling of exceptional conditions vulnerability. Crafted data that is passed to the JsonConvert.DeserializeObject method may trigger a StackOverflow exception resulting in denial of service. Depending on the usage of the library, an unauthenticated and remote attacker may be able to cause the denial of service condition.

Publish Date: 2024-01-03

URL: CVE-2024-21907

CVSS 3 Score Details (7.5)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Network
    • Attack Complexity: Low
    • Privileges Required: None
    • User Interaction: None
    • Scope: Unchanged
  • Impact Metrics:
    • Confidentiality Impact: None
    • Integrity Impact: None
    • Availability Impact: High

For more information on CVSS3 Scores, click here.

Suggested Fix

Type: Upgrade version

Origin: GHSA-5crp-9r3c-p9vr

Release Date: 2024-01-03

Fix Resolution: Newtonsoft.Json - 13.0.1

⛑️ Automatic Remediation will be attempted for this issue.


⛑️Automatic Remediation will be attempted for this issue.

xunit.2.5.0.nupkg: 3 vulnerabilities (highest severity is: 7.5)

Vulnerable Library - xunit.2.5.0.nupkg

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/system.text.regularexpressions/4.3.0/system.text.regularexpressions.4.3.0.nupkg

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Vulnerabilities

CVE Severity CVSS Dependency Type Fixed in (xunit.2.5.0.nupkg version) Remediation Possible**
CVE-2024-38095 High 7.5 system.formats.asn1.7.0.0.nupkg Transitive N/A*
CVE-2019-0820 High 7.5 system.text.regularexpressions.4.3.0.nupkg Transitive N/A*
CVE-2018-8292 Medium 5.3 system.net.http.4.3.0.nupkg Transitive N/A*

*For some transitive vulnerabilities, there is no version of direct dependency with a fix. Check the "Details" section below to see if there is a version of transitive dependency where vulnerability is fixed.

**In some cases, Remediation PR cannot be created automatically for a vulnerability despite the availability of remediation

Details

CVE-2024-38095

Vulnerable Library - system.formats.asn1.7.0.0.nupkg

Provides classes that can read and write the ASN.1 BER, CER, and DER data formats.

Commonly Used Types:
System.Formats.Asn1.AsnReader
System.Formats.Asn1.AsnWriter

Library home page: https://api.nuget.org/packages/system.formats.asn1.7.0.0.nupkg

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/system.formats.asn1/7.0.0/system.formats.asn1.7.0.0.nupkg

Dependency Hierarchy:

  • xunit.2.5.0.nupkg (Root Library)
    • xunit.assert.2.5.0.nupkg
      • netstandard.library.1.6.1.nupkg
        • system.security.cryptography.x509certificates.4.3.0.nupkg
          • system.security.cryptography.cng.5.0.0.nupkg
            • system.formats.asn1.7.0.0.nupkg (Vulnerable Library)

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Found in base branch: main

Vulnerability Details

.NET and Visual Studio Denial of Service Vulnerability

Publish Date: 2024-07-09

URL: CVE-2024-38095

CVSS 3 Score Details (7.5)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Network
    • Attack Complexity: Low
    • Privileges Required: None
    • User Interaction: None
    • Scope: Unchanged
  • Impact Metrics:
    • Confidentiality Impact: None
    • Integrity Impact: None
    • Availability Impact: High

For more information on CVSS3 Scores, click here.

Suggested Fix

Type: Upgrade version

Origin: GHSA-447r-wph3-92pm

Release Date: 2024-07-09

Fix Resolution: Microsoft.NetCore.App.Runtime - 6.0.32,8.0.7, System.Formats.Asn1 - 6.0.1,8.0.1

CVE-2019-0820

Vulnerable Library - system.text.regularexpressions.4.3.0.nupkg

Provides the System.Text.RegularExpressions.Regex class, an implementation of a regular expression e...

Library home page: https://api.nuget.org/packages/system.text.regularexpressions.4.3.0.nupkg

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/system.text.regularexpressions/4.3.0/system.text.regularexpressions.4.3.0.nupkg

Dependency Hierarchy:

  • xunit.2.5.0.nupkg (Root Library)
    • xunit.assert.2.5.0.nupkg
      • netstandard.library.1.6.1.nupkg
        • system.xml.xdocument.4.3.0.nupkg
          • system.xml.readerwriter.4.3.0.nupkg
            • system.text.regularexpressions.4.3.0.nupkg (Vulnerable Library)

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Found in base branch: main

Vulnerability Details

A denial of service vulnerability exists when .NET Framework and .NET Core improperly process RegEx strings, aka '.NET Framework and .NET Core Denial of Service Vulnerability'. This CVE ID is unique from CVE-2019-0980, CVE-2019-0981.
Mend Note: After conducting further research, Mend has determined that CVE-2019-0820 only affects environments with versions 4.3.0 and 4.3.1 only on netcore50 environment of system.text.regularexpressions.nupkg.

Publish Date: 2019-05-16

URL: CVE-2019-0820

CVSS 3 Score Details (7.5)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Network
    • Attack Complexity: Low
    • Privileges Required: None
    • User Interaction: None
    • Scope: Unchanged
  • Impact Metrics:
    • Confidentiality Impact: None
    • Integrity Impact: None
    • Availability Impact: High

For more information on CVSS3 Scores, click here.

Suggested Fix

Type: Upgrade version

Origin: GHSA-cmhx-cq75-c4mj

Release Date: 2019-05-16

Fix Resolution: System.Text.RegularExpressions - 4.3.1

CVE-2018-8292

Vulnerable Library - system.net.http.4.3.0.nupkg

Provides a programming interface for modern HTTP applications, including HTTP client components that allow applications to consume web services over HTTP and HTTP components that can be used by both clients and servers for parsing HTTP headers.

Library home page: https://api.nuget.org/packages/system.net.http.4.3.0.nupkg

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/system.net.http/4.3.0/system.net.http.4.3.0.nupkg

Dependency Hierarchy:

  • xunit.2.5.0.nupkg (Root Library)
    • xunit.assert.2.5.0.nupkg
      • netstandard.library.1.6.1.nupkg
        • system.net.http.4.3.0.nupkg (Vulnerable Library)

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Found in base branch: main

Vulnerability Details

An information disclosure vulnerability exists in .NET Core when authentication information is inadvertently exposed in a redirect, aka ".NET Core Information Disclosure Vulnerability." This affects .NET Core 2.1, .NET Core 1.0, .NET Core 1.1, PowerShell Core 6.0.

Publish Date: 2018-10-10

URL: CVE-2018-8292

CVSS 3 Score Details (5.3)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Network
    • Attack Complexity: Low
    • Privileges Required: None
    • User Interaction: None
    • Scope: Unchanged
  • Impact Metrics:
    • Confidentiality Impact: Low
    • Integrity Impact: None
    • Availability Impact: None

For more information on CVSS3 Scores, click here.

Suggested Fix

Type: Upgrade version

Release Date: 2018-10-10

Fix Resolution: System.Net.Http - 4.3.4;Microsoft.PowerShell.Commands.Utility - 6.1.0-rc.1

npgsql.entityframeworkcore.postgresql.7.0.4.nupkg: 1 vulnerabilities (highest severity is: 8.1)

Vulnerable Library - npgsql.entityframeworkcore.postgresql.7.0.4.nupkg

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/npgsql/7.0.4/npgsql.7.0.4.nupkg

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Vulnerabilities

CVE Severity CVSS Dependency Type Fixed in (npgsql.entityframeworkcore.postgresql.7.0.4.nupkg version) Remediation Possible**
CVE-2024-32655 High 8.1 npgsql.7.0.4.nupkg Transitive N/A*

*For some transitive vulnerabilities, there is no version of direct dependency with a fix. Check the "Details" section below to see if there is a version of transitive dependency where vulnerability is fixed.

**In some cases, Remediation PR cannot be created automatically for a vulnerability despite the availability of remediation

Details

CVE-2024-32655

Vulnerable Library - npgsql.7.0.4.nupkg

Npgsql is the open source .NET data provider for PostgreSQL.

Library home page: https://api.nuget.org/packages/npgsql.7.0.4.nupkg

Path to dependency file: /tests/Blogifier.Tests/Blogifier.Tests.csproj

Path to vulnerable library: /home/wss-scanner/.nuget/packages/npgsql/7.0.4/npgsql.7.0.4.nupkg

Dependency Hierarchy:

  • npgsql.entityframeworkcore.postgresql.7.0.4.nupkg (Root Library)
    • npgsql.7.0.4.nupkg (Vulnerable Library)

Found in HEAD commit: 39ddcd5516c1d38b0f187e6b8e96b6f19ff19826

Found in base branch: main

Vulnerability Details

Npgsql is the .NET data provider for PostgreSQL. The WriteBind() method in src/Npgsql/Internal/NpgsqlConnector.FrontendMessages.cs uses int variables to store the message length and the sum of parameter lengths. Both variables overflow when the sum of parameter lengths becomes too large. This causes Npgsql to write a message size that is too small when constructing a Postgres protocol message to send it over the network to the database. When parsing the message, the database will only read a small number of bytes and treat any following bytes as new messages while they belong to the old message. Attackers can abuse this to inject arbitrary Postgres protocol messages into the connection, leading to the execution of arbitrary SQL statements on the application's behalf. This vulnerability is fixed in 4.0.14, 4.1.13, 5.0.18, 6.0.11, 7.0.7, and 8.0.3.

Publish Date: 2024-05-09

URL: CVE-2024-32655

CVSS 3 Score Details (8.1)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Network
    • Attack Complexity: High
    • Privileges Required: None
    • User Interaction: None
    • Scope: Unchanged
  • Impact Metrics:
    • Confidentiality Impact: High
    • Integrity Impact: High
    • Availability Impact: High

For more information on CVSS3 Scores, click here.

Suggested Fix

Type: Upgrade version

Origin: https://www.cve.org/CVERecord?id=CVE-2024-32655

Release Date: 2024-05-09

Fix Resolution: Npgsql - 4.0.14,4.1.13,5.0.18,6.0.11,7.0.7,8.0.3

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.