Kck.FileStorage.Abstractions 4.8.0

There is a newer version of this package available.
See the version list below for details.
dotnet add package Kck.FileStorage.Abstractions --version 4.8.0
                    
NuGet\Install-Package Kck.FileStorage.Abstractions -Version 4.8.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="Kck.FileStorage.Abstractions" Version="4.8.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Kck.FileStorage.Abstractions" Version="4.8.0" />
                    
Directory.Packages.props
<PackageReference Include="Kck.FileStorage.Abstractions" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Kck.FileStorage.Abstractions --version 4.8.0
                    
#r "nuget: Kck.FileStorage.Abstractions, 4.8.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.
#:package Kck.FileStorage.Abstractions@4.8.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Kck.FileStorage.Abstractions&version=4.8.0
                    
Install as a Cake Addin
#tool nuget:?package=Kck.FileStorage.Abstractions&version=4.8.0
                    
Install as a Cake Tool

Kck.FileStorage.Abstractions

Provider-agnostic file storage abstractions — Upload, Download, Delete, Exists, and List operations backed by FTP, Azure Blob, or AWS S3 providers.

Installation

dotnet add package Kck.FileStorage.Abstractions

Quick Start

using Kck.FileStorage.Abstractions;

// Program.cs — a provider (FluentFtp, AzureBlob or AwsS3)
builder.Services.AddKckFileStorageAzureBlob(opt =>
{
    opt.ConnectionString = builder.Configuration["Storage:ConnectionString"];
    opt.ContainerName = "documents";
});

// Use IFileStorageService in a handler
public class DocumentHandler(IFileStorageService storage)
{
    public Task UploadAsync(Stream content, string fileName, CancellationToken ct) =>
        storage.UploadAsync(new FileUploadRequest
        {
            Content = content,
            FileName = Path.GetFileName(fileName), // never trust a client-supplied path
            DestinationPath = "documents"
        }, ct);

    public Task<Stream> DownloadAsync(string path, CancellationToken ct) => storage.DownloadAsync(path, ct);

    public Task DeleteAsync(string path, CancellationToken ct) => storage.DeleteAsync(path, ct);
}

Configuration

Property Description Default
FileStorage:Provider FluentFtp, AzureBlob, AwsS3 FluentFtp
FileStorage:BasePath Root path / container name "uploads"
FileStorage:MaxFileSizeBytes Upload size guard 104857600 (100 MB)

Resources

Product Compatible and additional computed target framework versions.
.NET 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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net10.0

    • No dependencies.

NuGet packages (3)

Showing the top 3 NuGet packages that depend on Kck.FileStorage.Abstractions:

Package Downloads
Kck.FileStorage.FluentFtp

FluentFTP-backed IFileStorageService with connection pooling (FtpConnectionPool). Supports SSL/TLS and configurable pool size for high-throughput scenarios. Path sanitization prevents directory traversal. Registered via AddKckFileStorageFluentFtp().

Kck.FileStorage.AwsS3

Amazon S3-backed IFileStorageService. Supports explicit AccessKey/SecretKey credentials or IAM role authentication, paginated ListObjectsV2, and optional KeyPrefix for multi-tenant bucket isolation. Registered via AddKckFileStorageAwsS3().

Kck.FileStorage.AzureBlob

Azure Blob Storage-backed IFileStorageService. Supports ConnectionString and Managed Identity (AccountName) authentication; the container is created on first use when CreateContainerIfNotExists is set. Registered via AddKckFileStorageAzureBlob().

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
5.0.0 298 11/2/2026
4.8.0 606 10/31/2026
Loading failed