hashicorp / hashicorp/consul

add option to enable x-forwarded-for header for gateways

Open
#9,148 3 comments 11 reactions 0 assignees View on GitHub
theme/connect theme/ingress-gw
Dominant language
Go
Stars
30.1k
Forks
4.6k
Avg merge
1d 18h
Merged PRs (30d)
39

Description

#### Feature Description

consul version: v1.8.3

Needs an option to enable the `use_remote_address` option when setting up http listener for envoy ingress gateway.
According to envoy docs:
```
In general, use_remote_address should be set to true when Envoy is deployed as an edge node (aka a front proxy), whereas it may need to be set to false when Envoy is used as an internal service node in a mesh deployment.
```

#### Use Case(s)

Need the option so that the service can get the real ip address of the requester.

#### Note

We are using consul ingress gateway feature in nomad: https://www.nomadproject.io/docs/job-specification/gateway#gateway-stanza, so this option probably needs to be surfaced there as well in order to be used.

Contributor guide

Open the contributing guide

Research direction

Start by tracing the HTTP listener setup for the Envoy ingress gateway and the Consul ingress gateway configuration referenced by the Nomad gateway stanza. Confirm how an option can surface Envoy's use_remote_address setting and verify that the resulting service can receive the requester's real IP address.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
api, networking
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.