EgressPool.DependencyInjection
26.9.15.6302
See the version list below for details.
dotnet add package EgressPool.DependencyInjection --version 26.9.15.6302
NuGet\Install-Package EgressPool.DependencyInjection -Version 26.9.15.6302
<PackageReference Include="EgressPool.DependencyInjection" Version="26.9.15.6302" />
<PackageVersion Include="EgressPool.DependencyInjection" Version="26.9.15.6302" />
<PackageReference Include="EgressPool.DependencyInjection" />
paket add EgressPool.DependencyInjection --version 26.9.15.6302
#r "nuget: EgressPool.DependencyInjection, 26.9.15.6302"
#:package EgressPool.DependencyInjection@26.9.15.6302
#addin nuget:?package=EgressPool.DependencyInjection&version=26.9.15.6302
#tool nuget:?package=EgressPool.DependencyInjection&version=26.9.15.6302
EgressPool
A .NET library for sending outbound TCP, UDP, and HTTP traffic from a pool of source IP addresses. Outbound connections appear from different local addresses while the calling code stays simple.
Features
- Configure IPv4 or IPv6 prefixes, or auto-detect them from local interfaces.
- Create TCP, UDP, or HTTP clients bound to addresses from those prefixes.
- Select prefixes by destination scope.
- Release addresses by disposing clients, sockets, leases, or the pool itself.
Quick Start
using Egress;
await using EgressPool pool = await EgressPool.CreateAsync();
using HttpClient client = pool.CreateHttpClient();
string response = await client.GetStringAsync("http://127.0.0.1:5000/");
Dependency Injection
Install EgressPool.DependencyInjection and register with your service collection:
builder.Services.AddEgressPool();
builder.Services.AddHttpClient("egress").UseEgressPool();
Running in Containers
Containers need host networking, root access, and the NET_ADMIN capability so the pool can bind to and configure host interfaces.
docker run --network host --user root --cap-add NET_ADMIN your-image
Docker Compose equivalent:
services:
app:
image: your-image
network_mode: host
user: root
cap_add:
- NET_ADMIN
Expected Behavior
Each outbound connection uses a source address from the pool. Disposing the connection, client, or pool releases the address.
Some configurations require elevated permissions. If unavailable, pool or connection creation throws an exception.
| 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
- EgressPool (>= 26.9.15.6302)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 26.10.13.8169 | 41 | 10/13/2026 |
| 26.10.13.6683 | 74 | 10/13/2026 |
| 26.10.12.1915 | 113 | 10/12/2026 |
| 26.10.9.8173 | 116 | 10/9/2026 |
| 26.10.7.5571 | 117 | 10/7/2026 |
| 26.10.5.2587 | 139 | 10/5/2026 |
| 26.9.29.6677 | 128 | 9/29/2026 |
| 26.9.28.2560 | 126 | 9/28/2026 |
| 26.9.27.9669 | 124 | 9/27/2026 |
| 26.9.25.7417 | 126 | 9/25/2026 |
| 26.9.23.7351 | 136 | 9/23/2026 |
| 26.9.21.5171 | 135 | 9/21/2026 |
| 26.9.21.2926 | 134 | 9/21/2026 |
| 26.9.20.1342 | 136 | 9/20/2026 |
| 26.9.15.6302 | 139 | 9/15/2026 |
| 26.9.14.2926 | 134 | 9/14/2026 |
| 26.9.11.5171 | 136 | 9/11/2026 |
| 26.9.9.4799 | 140 | 9/9/2026 |
| 26.9.8.8917 | 141 | 9/8/2026 |
| 26.9.7.2181 | 145 | 9/7/2026 |