Isopoh.Cryptography.SecureArray 2.0.0

dotnet add package Isopoh.Cryptography.SecureArray --version 2.0.0                
NuGet\Install-Package Isopoh.Cryptography.SecureArray -Version 2.0.0                
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Isopoh.Cryptography.SecureArray" Version="2.0.0" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Isopoh.Cryptography.SecureArray --version 2.0.0                
#r "nuget: Isopoh.Cryptography.SecureArray, 2.0.0"                
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install Isopoh.Cryptography.SecureArray as a Cake Addin
#addin nuget:?package=Isopoh.Cryptography.SecureArray&version=2.0.0

// Install Isopoh.Cryptography.SecureArray as a Cake Tool
#tool nuget:?package=Isopoh.Cryptography.SecureArray&version=2.0.0                

Isopoh

SecureArray

You can think of the SecureArray sort of like you would think of SecureString except that SecureString does crypto (usually - encryption isn't supported everywhere) to protect its sensitive data and has windows of vulnerability when it decrypts the string for use. SecureArray protects its data by locking the data into RAM to keep it from swapping to disk and also zeroing the buffer when disposed. So, unlike SecureString, any process with access to your process's memory will be able to read the data in your SecureArray, but you do not have to worry about your data persisting anywhere or multiple copies of your data floating around RAM due to C#'s memory management.

Because it locks the memory into RAM (and at a non-movable-by-the-garbage-collector location), you need to use it as infrequently as possible and for as short a time as possible. RAM secured this way puts stress on the computer as a whole by denying physical RAM for other processes and puts stress on your particular executable by denying freedom to the garbage collector to reduce fragmentation as needed for best performance.

Note: when using SecureArray in the browser (for example, under Blazor or UnoPlatform), the memory cannot be locked into RAM so SecureArray does its best effort to protect the data by zeroing the buffer when it is disposed.

Note similarly: when using SecureArray in a Universal Windows Platform (UWP) application, I have yet to figure out how to use the supposedly available VirtualAllocFromApp() system call to lock memory into RAM so SecureArray does its best effort to protect the data by zeroing the buffer when it is disposed.

Always dispose of your SecureArrays.

API GENERATION

The API Documentation at https://mheyman.github.io/Isopoh.Cryptography.Argon2 gets generated automatically upon build. This happens via a dummy C# "Doc" project that uses the DocFx NuGet package to produce the API documentation.

AUTHOR

Michael Heyman

ACKNOWLEDGMENTS

List of people and project that inspired creation of this one:

  • The many contributers of the Argon2 repository
  • and the cryptographers responsible for creating and testing that algorithm
  • @CodesInChaos for the fully managed Blake2b implementation here
  • @PurpleBooth for his readme template posted here

LICENSE

<a rel="license" href="http://creativecommons.org/licenses/by/4.0/"><img alt="Creative Commons License" style="border-width:0" src="https://i.creativecommons.org/l/by/4.0/88x31.png" /></a><br /><span xmlns:dct="http://purl.org/dc/terms/" property="dct:title">Isopoh.Cryptography.Argon2</span> by <a xmlns:cc="http://creativecommons.org/ns#" href="https://github.com/mheyman/Isopoh.Cryptography.Argon2" property="cc:attributionName" rel="cc:attributionURL">Michael Heyman</a> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/4.0/">Creative Commons Attribution 4.0 International License</a>.

PRODUCTION STATUS & SUPPORT

You should be aware that this project is supported solely by me and provided as is.

Go back to the top

Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 is compatible.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 is compatible.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
.NET Core netcoreapp2.0 was computed.  netcoreapp2.1 was computed.  netcoreapp2.2 was computed.  netcoreapp3.0 was computed.  netcoreapp3.1 is compatible. 
.NET Standard netstandard2.0 is compatible.  netstandard2.1 was computed. 
.NET Framework net461 was computed.  net462 was computed.  net463 was computed.  net47 was computed.  net471 was computed.  net472 was computed.  net48 was computed.  net481 was computed. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen40 was computed.  tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • .NETCoreApp 3.1

    • No dependencies.
  • .NETStandard 2.0

    • No dependencies.
  • net6.0

    • No dependencies.
  • net7.0

    • No dependencies.

NuGet packages (4)

Showing the top 4 NuGet packages that depend on Isopoh.Cryptography.SecureArray:

Package Downloads
Isopoh.Cryptography.Blake2b

Blake2 hash for sensitive data. Uses Isopoh.Cryptography.SecureArray to assure sensitive data gets wiped from RAM and, if the operating system allows, never gets written to disk.

Isopoh.Cryptography.Argon2

Argon2 Password Hasher written in C#. Uses Isopoh.Cryptography.Blake2 for hashing and Isopoh.Cryptography.SecureArray to protect sensitive data.

Secp256k1.ZKP.Net

This package contains platform-specific native code builds of secp256k1. Included:win-x86/libsecp256k1.dll, win-x64/libsecp256k1.dll, osx-x64/libsecp256k1.dylib and linux-x64/libsecp256k1.so

Athi.Whippet.Security

Package Description

GitHub repositories (1)

Showing the top 1 popular GitHub repositories that depend on Isopoh.Cryptography.SecureArray:

Repository Stars
johnstaveley/SecurityEssentials
Raise your baseline in security by using this as your template instead of default Mvc project. Keep your app secure by continuously applying Security rules
Version Downloads Last updated
2.0.0 340,027 8/17/2023
1.1.12 390,282 5/22/2022
1.1.11 70,413 12/12/2021
1.1.10 523,836 11/18/2020
1.1.9 21,579 10/2/2020
1.1.8 52,193 7/26/2020
1.1.7 987 7/26/2020
1.1.6 1,313 7/25/2020
1.1.5 1,012 7/25/2020
1.1.4 5,680 7/5/2020
1.1.3 95,596 10/27/2019
1.1.2 117,264 5/14/2019
1.1.1 2,823 2/16/2019
1.1.0 1,139 2/16/2019
1.0.10 1,692 2/10/2019
1.0.9 1,155 2/10/2019
1.0.8 91,760 3/11/2018
1.0.7 1,317 3/11/2018
1.0.6 12,381 1/13/2018
1.0.5 1,568 10/29/2017
1.0.4 1,435 9/23/2017
1.0.3 980 9/10/2017
1.0.2 1,839 8/31/2017
1.0.1 2,088 3/8/2017
1.0.0 2,753 7/31/2016

Bump version to match Isopoh.Cryptography.Argon2.