Soenneker.Aws.BasicCredentials
4.0.329
Prefix Reserved
dotnet add package Soenneker.Aws.BasicCredentials --version 4.0.329
NuGet\Install-Package Soenneker.Aws.BasicCredentials -Version 4.0.329
<PackageReference Include="Soenneker.Aws.BasicCredentials" Version="4.0.329" />
<PackageVersion Include="Soenneker.Aws.BasicCredentials" Version="4.0.329" />
<PackageReference Include="Soenneker.Aws.BasicCredentials" />
paket add Soenneker.Aws.BasicCredentials --version 4.0.329
#r "nuget: Soenneker.Aws.BasicCredentials, 4.0.329"
#:package Soenneker.Aws.BasicCredentials@4.0.329
#addin nuget:?package=Soenneker.Aws.BasicCredentials&version=4.0.329
#tool nuget:?package=Soenneker.Aws.BasicCredentials&version=4.0.329
Soenneker.Aws.BasicCredentials
Creates and caches the AWS SDK's BasicAWSCredentials from application configuration.
Installation
dotnet add package Soenneker.Aws.BasicCredentials
Configuration
The utility requires these keys:
{
"Aws": {
"AccessKey": "access-key-id",
"SecretKey": "secret-access-key"
}
}
Use a secret provider or environment variables (Aws__AccessKey and Aws__SecretKey) in deployed applications. Do not commit credentials to configuration files.
Registration and use
using Amazon.Runtime;
using Soenneker.Aws.BasicCredentials.Abstract;
using Soenneker.Aws.BasicCredentials.Registrars;
builder.Services.AddBasicAwsCredentialsUtilAsSingleton();
public sealed class AwsClientFactory(IBasicAwsCredentialsUtil credentialsUtil)
{
public async ValueTask<BasicAWSCredentials> GetCredentials(
CancellationToken cancellationToken) =>
await credentialsUtil.Get(cancellationToken);
}
GetSync() is available for callers that cannot use the asynchronous API.
Lifecycle and security
- Credentials are created on first access and reused for the utility's lifetime.
- Configuration changes and rotated keys are not picked up after initialization; replace or dispose the utility to create a new credential object.
- Missing configuration fails credential creation rather than returning blank credentials.
BasicAWSCredentialsrepresents long-lived access keys. Prefer an AWS role or temporary credential provider when the hosting environment supports one.- Let the DI container dispose registered instances. Do not log the credential object or its secret values.
| Product | Versions 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. |
-
net10.0
- AWSSDK.Core (>= 4.0.102.6)
- Soenneker.Extensions.Configuration (>= 4.0.895)
- Soenneker.Utils.AsyncSingleton (>= 4.0.849)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on Soenneker.Aws.BasicCredentials:
| Package | Downloads |
|---|---|
|
Soenneker.Aws.Route53.DomainsClientUtil
A .NET thread-safe singleton For AWS's Route53 domain client, AmazonRoute53DomainsClient |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 4.0.329 | 0 | 9/16/2026 |
| 4.0.328 | 28 | 9/16/2026 |
| 4.0.327 | 54 | 9/15/2026 |
| 4.0.326 | 78 | 9/15/2026 |
| 4.0.325 | 79 | 9/13/2026 |
| 4.0.324 | 62 | 9/13/2026 |
| 4.0.323 | 79 | 9/13/2026 |
| 4.0.322 | 70 | 9/12/2026 |
| 4.0.321 | 57 | 9/12/2026 |
| 4.0.320 | 85 | 9/12/2026 |
| 4.0.319 | 107 | 9/11/2026 |
| 4.0.318 | 99 | 9/10/2026 |
| 4.0.317 | 126 | 9/9/2026 |
| 4.0.316 | 115 | 9/9/2026 |
| 4.0.315 | 114 | 9/8/2026 |
| 4.0.314 | 124 | 9/8/2026 |
| 4.0.313 | 120 | 9/8/2026 |
| 4.0.312 | 125 | 9/7/2026 |
| 4.0.311 | 142 | 9/7/2026 |
| 4.0.310 | 135 | 9/5/2026 |
Updated Multiple NuGet packages