View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0000644 | file | General | public | 2025-04-14 19:36 | 2025-04-14 19:36 |
Reporter | omajid | Assigned To | |||
Priority | normal | Severity | feature | Reproducibility | always |
Status | new | Resolution | open | ||
Product Version | 5.45 | ||||
Summary | 0000644: file doesn't recognize .nupkg files correctly | ||||
Description | The NuGet package format is a format used by the .NET programming framework: https://en.wikipedia.org/wiki/NuGet NuGet packages are essentially zip files with a custom extension (".nupkg") and contain a few common files by convention, but can contain essentially any other file, specially binaries such as .NET assemblies in the form of Windows Portable Executable files (".dll") or even Unix shared libraries (".so"). The version of file I used confuses them with Microsoft OOXML and Zip archive data files. | ||||
Steps To Reproduce | Here's a test case. It downloads a bunch of nuget packages, and runs file over them. The majority are classified as zip archives, but a number of them are incorrectly classified as OOXML files. #!/bin/bash set -euo pipefail set -x function download_and_test_package { name=$1 version=$2 wget -O $name-$version.nupkg https://www.nuget.org/api/v2/package/$name/$version --no-verbose file $name-$version.nupkg } download_and_test_package AutoMapper 14.0.0 download_and_test_package AWSSDK.Core 3.7.402.39 download_and_test_package Azure.Core 1.45.0 download_and_test_package Dapper 2.1.66 download_and_test_package FSharp.Core 9.0.101 download_and_test_package Google.Protobuf 3.30.2 download_and_test_package Microsoft.ApplicationInsights 2.23.0 download_and_test_package Microsoft.AspNetCore.App.Runtime.linux-x64 9.0.4 download_and_test_package Microsoft.Extensions.DependencyInjection 9.0.4 download_and_test_package Microsoft.Identity.Client 4.70.2 download_and_test_package Microsoft.NET.ILLink.Tasks 10.0.0-preview.3.25171.5 download_and_test_package Microsoft.NETCore.App.Runtime.linux-x64 9.0.4 download_and_test_package Microsoft.OpenApi 1.6.24 download_and_test_package Moq 4.20.72 download_and_test_package Newtonsoft.Json 13.0.3 download_and_test_package Npgsql 9.0.3 download_and_test_package Polly 8.5.2 download_and_test_package runtime.linux-arm.runtime.native.System.IO.Ports 9.0.3 download_and_test_package runtime.linux-x64.Microsoft.DotNet.ILCompiler 9.0.0 download_and_test_package Serilog 4.2.0 download_and_test_package System.Runtime.CompilerServices.Unsafe 6.1.2 | ||||
Tags | magic, zip | ||||