Provance.Core
0.0.3
dotnet add package Provance.Core --version 0.0.3
NuGet\Install-Package Provance.Core -Version 0.0.3
<PackageReference Include="Provance.Core" Version="0.0.3" />
<PackageVersion Include="Provance.Core" Version="0.0.3" />
<PackageReference Include="Provance.Core" />
paket add Provance.Core --version 0.0.3
#r "nuget: Provance.Core, 0.0.3"
#:package Provance.Core@0.0.3
#addin nuget:?package=Provance.Core&version=0.0.3
#tool nuget:?package=Provance.Core&version=0.0.3
<p align="center"> <img src="provanceCore.png" alt="PROVANCE Core logo" width="120" /> </p>
Provance.Core
Core SDK for PROVANCE: tamper-evident audit trails via HMAC-SHA256 hash-chaining and a single-writer ledger (anti-fork) model.
- Repo docs: see the root README in the repository.
- NuGet:
Provance.Core
Install
dotnet add package Provance.Core
What you get
LedgerEntrymodel (hash-chaining fields +Sequence)ILedgerServicefor producing entries and verifying integrity- Single Writer background service (linearizes concurrent producers)
- In-memory store for demos/tests (
InMemoryLedgerStore)
For ASP.NET Core integration, use Provance.AspNetCore.Middleware.
Minimal DI (Worker / Console)
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Hosting;
using Provance.Core.Options;
using Provance.Core.Services;
using Provance.Core.Services.Interfaces;
using Provance.Core.Services.Internal;
var host = Host.CreateDefaultBuilder(args)
.ConfigureServices(services =>
{
services.Configure<ProvanceOptions>(o =>
{
o.GenesisHash = "0000000000000000000000000000000000000000000000000000000000000000";
o.SecretKey = "CHANGE_ME_IN_PROD";
});
services.AddSingleton<IEntryQueue, EntryQueue>();
services.AddSingleton<ILedgerService, LedgerService>();
// DEV/TEST ONLY (use a real store in prod)
services.AddSingleton<ILedgerStore, InMemoryLedgerStore>();
// Single Writer
services.AddHostedService<LedgerWriterService>();
})
.Build();
await host.RunAsync();
Compatibility notes
- v0.x is pre-release: breaking changes may occur.
- v0.0.3 introduces
Sequenceas the deterministic ordering key; start a new ledger collection when upgrading from v0.0.2.
License
MIT
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net8.0 is compatible. 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. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- Microsoft.Extensions.Hosting (>= 10.0.0)
- Polly (>= 8.6.5)
-
net8.0
- Microsoft.Extensions.Hosting (>= 10.0.0)
- Polly (>= 8.6.5)
NuGet packages (2)
Showing the top 2 NuGet packages that depend on Provance.Core:
| Package | Downloads |
|---|---|
|
Provance.AspNetCore.Middleware
ASP.NET Core middleware + DI helpers for PROVANCE tamper-evident audit trails. |
|
|
Provance.Storage.MongoDB
MongoDB storage provider for PROVANCE (ILedgerStore) with deterministic ordering and single-writer lease support. |
GitHub repositories
This package is not used by any popular GitHub repositories.
v0.0.3: Single-writer correctness + Sequence ordering.