Skip to content

Track upstreaming header forwarding fix - #2

Closed
fopina-ci wants to merge 1 commit into
mainfrom
upstream-header-followup-placeholder
Closed

fopina-ci wants to merge 1 commit into
mainfrom
upstream-header-followup-placeholder

Conversation

@fopina-ci

Copy link
Copy Markdown
Collaborator

This is a PR-as-issue because Issues are disabled on this fork.

Reference implementation PR:
#1

TODO:

The placeholder file exists only to keep this tracking PR open.

@fopina

fopina commented Jun 6, 2026

Copy link
Copy Markdown
Owner

Working on gotlsproxy issue Danny-Dasilva#7:
fopina/gotlsproxy#7

Goal:
Improve CycleTLS header forwarding behavior in gotlsproxy.

Issue Danny-Dasilva#7 asks for two related fixes:

  1. Support multiple values for request headers
    Current gotlsproxy code flattens req.Header into map[string]string for cycletls.Options.Headers.
    That drops all but the first value for headers with multiple values.

  2. Preserve request header name casing
    CycleTLS internally uses Header.Set(k, v), which canonicalizes header names.
    Some servers are sensitive to header casing even though HTTP says they should not be.

Important dependency context:
CycleTLS project:
https://github.com/Danny-Dasilva/CycleTLS

Relevant CycleTLS issues / PRs:

Conclusion:
A gotlsproxy-only fix can join repeated request header values, but cannot fully preserve header casing because CycleTLS canonicalizes internally. Cleanest full fix is in CycleTLS: add support for multi-value request headers and assign directly into fhttp.Header instead of using Header.Set.

@fopina fopina closed this Jun 7, 2026
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