Skip to content

fix: resolve forwarded headers section#2

Merged
PANiXiDA merged 2 commits into
mainfrom
feature/forwarded-headers-root-configuration
Jun 18, 2026
Merged

fix: resolve forwarded headers section#2
PANiXiDA merged 2 commits into
mainfrom
feature/forwarded-headers-root-configuration

Conversation

@PANiXiDA

Copy link
Copy Markdown
Contributor

What changed

  • AddHttp can now receive the root application IConfiguration.
  • The package resolves the standard ForwardedHeaders section internally when it is present.
  • Existing callers that pass a custom forwarded headers section still work.
  • README examples now use builder.Services.AddHttp(builder.Configuration).

Why

  • Consumers should not need to call configuration.GetSection(ForwardedHeaders) at every application entry point.
  • Forwarded headers configuration stays centralized in the package.

How to verify locally

  • dotnet restore
  • dotnet format
  • dotnet build --configuration Release
  • dotnet test --configuration Release

Migrations / contracts / config / breaking changes

  • No migrations.
  • No breaking public API change.
  • Configuration remains compatible with both root IConfiguration and an explicitly selected forwarded headers section.

@PANiXiDA PANiXiDA merged commit c9c86fa into main Jun 18, 2026
4 checks passed
@PANiXiDA PANiXiDA deleted the feature/forwarded-headers-root-configuration branch June 19, 2026 18:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants