![]() |
VOOZH | about |
dotnet add package System.IO.Hashing --version 10.0.9
NuGet\Install-Package System.IO.Hashing -Version 10.0.9
<PackageReference Include="System.IO.Hashing" Version="10.0.9" />
<PackageVersion Include="System.IO.Hashing" Version="10.0.9" />Directory.Packages.props
<PackageReference Include="System.IO.Hashing" />Project file
paket add System.IO.Hashing --version 10.0.9
#r "nuget: System.IO.Hashing, 10.0.9"
#:package System.IO.Hashing@10.0.9
#addin nuget:?package=System.IO.Hashing&version=10.0.9Install as a Cake Addin
#tool nuget:?package=System.IO.Hashing&version=10.0.9Install as a Cake Tool
System.IO.Hashing offers a variety of hash code algorithms.
Hash code algorithms are pivotal for generating unique values for objects based on their content, facilitating object comparisons, and detecting content alterations. The namespace encompasses algorithms like CRC-32, CRC-64, xxHash3, xxHash32, xxHash64, and xxHash128, all engineered for swift and efficient hash code generation, with xxHash being an "Extremely fast hash algorithm".
Warning: The hash functions provided by System.IO.Hashing are not suitable for security purposes such as handling passwords or verifying untrusted content. For such security-critical applications, consider using cryptographic hash functions provided by the System.Security.Cryptography namespace.
Creating hash codes is straightforward.
Call the Hash method with the content to be hashed.
Here is a practical example:
using System;
using System.IO.Hashing;
byte[] data = new byte[] { 1, 2, 3, 4 };
byte[] crc32Value = Crc32.Hash(data);
Console.WriteLine($"CRC-32 Hash: {BitConverter.ToString(crc32Value)}");
// CRC-32 Hash: CD-FB-3C-B6
byte[] crc64Value = Crc64.Hash(data);
Console.WriteLine($"CRC-64 Hash: {BitConverter.ToString(crc64Value)}");
// CRC-64 Hash: 58-8D-5A-D4-2A-70-1D-B2
byte[] xxHash3Value = XxHash3.Hash(data);
Console.WriteLine($"XxHash3 Hash: {BitConverter.ToString(xxHash3Value)}");
// XxHash3 Hash: 98-8B-7B-90-33-AC-46-22
byte[] xxHash32Value = XxHash32.Hash(data);
Console.WriteLine($"XxHash32 Hash: {BitConverter.ToString(xxHash32Value)}");
// XxHash32 Hash: FE-96-D1-9C
byte[] xxHash64Value = XxHash64.Hash(data);
Console.WriteLine($"XxHash64 Hash: {BitConverter.ToString(xxHash64Value)}");
// XxHash64 Hash: 54-26-20-E3-A2-A9-2E-D1
byte[] xxHash128Value = XxHash128.Hash(data);
Console.WriteLine($"XxHash128 Hash: {BitConverter.ToString(xxHash128Value)}");
// XxHash128 Hash: 49-A0-48-99-59-7A-35-67-53-76-53-A0-D9-95-5B-86
The main types provided by this library are:
System.IO.Hashing.Crc32System.IO.Hashing.Crc64System.IO.Hashing.XxHash3System.IO.Hashing.XxHash32System.IO.Hashing.XxHash64System.IO.Hashing.XxHash128Cryptographic services, including secure encryption and decryption of data: System.Security.Cryptography
System.IO.Hashing is released as open source under the MIT license. Bug reports and contributions are welcome at the GitHub repository.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 net5.0 was computed. net5.0-windows net5.0-windows was computed. net6.0 net6.0 was computed. net6.0-android net6.0-android was computed. net6.0-ios net6.0-ios was computed. net6.0-maccatalyst net6.0-maccatalyst was computed. net6.0-macos net6.0-macos was computed. net6.0-tvos net6.0-tvos was computed. net6.0-windows net6.0-windows was computed. net7.0 net7.0 was computed. net7.0-android net7.0-android was computed. net7.0-ios net7.0-ios was computed. net7.0-maccatalyst net7.0-maccatalyst was computed. net7.0-macos net7.0-macos was computed. net7.0-tvos net7.0-tvos was computed. net7.0-windows net7.0-windows was computed. net8.0 net8.0 is compatible. net8.0-android net8.0-android was computed. net8.0-browser net8.0-browser was computed. net8.0-ios net8.0-ios was computed. net8.0-maccatalyst net8.0-maccatalyst was computed. net8.0-macos net8.0-macos was computed. net8.0-tvos net8.0-tvos was computed. net8.0-windows net8.0-windows was computed. net9.0 net9.0 is compatible. net9.0-android net9.0-android was computed. net9.0-browser net9.0-browser was computed. net9.0-ios net9.0-ios was computed. net9.0-maccatalyst net9.0-maccatalyst was computed. net9.0-macos net9.0-macos was computed. net9.0-tvos net9.0-tvos was computed. net9.0-windows net9.0-windows was computed. net10.0 net10.0 is compatible. net10.0-android net10.0-android was computed. net10.0-browser net10.0-browser was computed. net10.0-ios net10.0-ios was computed. net10.0-maccatalyst net10.0-maccatalyst was computed. net10.0-macos net10.0-macos was computed. net10.0-tvos net10.0-tvos was computed. net10.0-windows net10.0-windows was computed. |
| .NET Core | netcoreapp2.0 netcoreapp2.0 was computed. netcoreapp2.1 netcoreapp2.1 was computed. netcoreapp2.2 netcoreapp2.2 was computed. netcoreapp3.0 netcoreapp3.0 was computed. netcoreapp3.1 netcoreapp3.1 was computed. |
| .NET Standard | netstandard2.0 netstandard2.0 is compatible. netstandard2.1 netstandard2.1 was computed. |
| .NET Framework | net461 net461 was computed. net462 net462 is compatible. net463 net463 was computed. net47 net47 was computed. net471 net471 was computed. net472 net472 was computed. net48 net48 was computed. net481 net481 was computed. |
| MonoAndroid | monoandroid monoandroid was computed. |
| MonoMac | monomac monomac was computed. |
| MonoTouch | monotouch monotouch was computed. |
| Tizen | tizen40 tizen40 was computed. tizen60 tizen60 was computed. |
| Xamarin.iOS | xamarinios xamarinios was computed. |
| Xamarin.Mac | xamarinmac xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos xamarinwatchos was computed. |
Showing the top 5 NuGet packages that depend on System.IO.Hashing:
| Package | Downloads |
|---|---|
|
StackExchange.Redis
High performance Redis client, incorporating both synchronous and asynchronous usage. |
|
|
Azure.Storage.Common
This client library enables working with the Microsoft Azure Storage services which include the blob and file services for storing binary and text data, and the queue service for storing messages that may be accessed by a client. For this release see notes - https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/storage/Azure.Storage.Common/README.md and https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/storage/Azure.Storage.Common/CHANGELOG.md in addition to the breaking changes https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/storage/Azure.Storage.Common/BreakingChanges.txt Microsoft Azure Storage quickstarts and tutorials - https://docs.microsoft.com/en-us/azure/storage/ Microsoft Azure Storage REST API Reference - https://docs.microsoft.com/en-us/rest/api/storageservices/ |
|
|
SixLabors.ImageSharp
A new, fully featured, fully managed, cross-platform, 2D graphics API for .NET |
|
|
Microsoft.Build.Tasks.Git
MSBuild tasks providing git repository information. |
|
|
NServiceBus
Build, version, and monitor better microservices with the most powerful service platform for .NET |
Showing the top 20 popular GitHub repositories that depend on System.IO.Hashing:
| Repository | Stars |
|---|---|
|
files-community/Files
A modern file manager that helps users organize their files and folders.
|
|
|
dotnet/roslyn
The Roslyn .NET compiler provides C# and Visual Basic languages with rich code analysis APIs.
|
|
|
babalae/better-genshin-impact
📦BetterGI · 更好的原神 - 自动拾取 | 自动剧情 | 全自动钓鱼(AI) | 全自动七圣召唤 | 自动伐木 | 自动刷本 | 自动采集/挖矿/锄地 | 一条龙 | 全连音游 | 自动烹饪 - UI Automation Testing Tools For Genshin Impact
|
|
|
dotnet/BenchmarkDotNet
Powerful .NET library for benchmarking
|
|
|
dotnet/orleans
Cloud Native application framework for .NET
|
|
|
dotnet/yarp
A toolkit for developing high-performance HTTP reverse proxy applications.
|
|
|
LykosAI/StabilityMatrix
Multi-Platform Package Manager for Stable Diffusion
|
|
|
OrchardCMS/OrchardCore
Orchard Core is an open-source modular and multi-tenant application framework built with ASP.NET Core, and a content management system (CMS) built on top of that framework.
|
|
|
SixLabors/ImageSharp
:camera: A modern, cross-platform, 2D Graphics library for .NET
|
|
|
StackExchange/StackExchange.Redis
General purpose redis client
|
|
|
microsoft/aspire
Aspire is the tool for code-first, extensible, observable dev and deploy.
|
|
|
Azure/azure-sdk-for-net
This repository is for active development of the Azure SDK for .NET. For consumers of the SDK we recommend visiting our public developer docs at https://learn.microsoft.com/dotnet/azure/ or our versioned developer docs at https://azure.github.io/azure-sdk-for-net.
|
|
|
ChilliCream/graphql-platform
Welcome to the home of the Hot Chocolate GraphQL server for .NET, the Strawberry Shake GraphQL client for .NET and Nitro the awesome Monaco based GraphQL IDE.
|
|
|
dotnet/winforms
Windows Forms is a .NET UI framework for building Windows desktop applications.
|
|
|
Scighost/Starward
Game Launcher for miHoYo - 米家游戏启动器
|
|
|
Revolutionary-Games/Thrive
The main repository for the development of the evolution game Thrive.
|
|
|
neo-project/neo
NEO Smart Economy
|
|
|
JasperFx/marten
.NET Transactional Document DB and Event Store on PostgreSQL
|
|
|
0x90d/videoduplicatefinder
Video Duplicate Finder - Crossplatform
|
|
|
dotnet/sdk
Core functionality needed to create .NET Core projects, that is shared between Visual Studio and CLI
|
| Version | Downloads | Last Updated |
|---|---|---|
| 11.0.0-preview.5.26302.115 | 992 | 6/9/2026 |
| 11.0.0-preview.4.26230.115 | 4,828 | 5/12/2026 |
| 11.0.0-preview.3.26207.106 | 3,048 | 4/14/2026 |
| 11.0.0-preview.2.26159.112 | 7,273 | 3/10/2026 |
| 11.0.0-preview.1.26104.118 | 4,007 | 2/10/2026 |
| 10.0.9 | 382,704 | 6/9/2026 |
| 10.0.8 | 2,853,264 | 5/12/2026 |
| 10.0.7 | 1,745,233 | 4/21/2026 |
| 10.0.6 | 563,893 | 4/14/2026 |
| 10.0.5 | 2,536,400 | 3/12/2026 |
| 10.0.4 | 222,549 | 3/10/2026 |
| 10.0.3 | 7,708,165 | 2/10/2026 |
| 10.0.2 | 13,672,757 | 1/13/2026 |
| 10.0.1 | 20,639,971 | 12/9/2025 |
| 9.0.17 | 1,441 | 6/9/2026 |
| 9.0.16 | 11,741 | 5/12/2026 |
| 9.0.15 | 54,327 | 4/14/2026 |
| 9.0.14 | 129,757 | 3/10/2026 |
| 9.0.13 | 119,892 | 2/10/2026 |
| 9.0.12 | 790,277 | 1/13/2026 |