Skip to content

jshttp: populate RemoteAddr in http.Request#189

Merged
syumai merged 1 commit intosyumai:mainfrom
b0ch3nski:http-request-ip
Feb 15, 2026
Merged

jshttp: populate RemoteAddr in http.Request#189
syumai merged 1 commit intosyumai:mainfrom
b0ch3nski:http-request-ip

Conversation

@b0ch3nski
Copy link
Contributor

What

Populate RemoteAddr in http.Request with the client IP address.

Motivation

Cloudflare exposes extra HTTP Headers which we can use to fill the RemoteAddr field.

This works even when running on Wrangler locally.

Signed-off-by: Piotr Bocheński <piotr@bochen.ski>
Copy link
Owner

@syumai syumai left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@syumai syumai merged commit 01b96bc into syumai:main Feb 15, 2026
2 checks passed
@b0ch3nski b0ch3nski deleted the http-request-ip branch February 15, 2026 12:29
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