spring-cloud / spring-cloud/spring-cloud-gateway

A filter to drop "all" the request or response headers by default

Open
#2,941 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

waiting for votes
Dominant language
Java
Stars
4.9k
Forks
3.5k
Avg merge
20h 57m
Merged PRs (30d)
8

Description

Is your feature request related to a problem? Please describe.
I can't seem to find a filter which allows me to drop all the headers or in other words whitelist only the headers that I recognize. This is around security so I can prevent unidentified headers reaching my service.

Describe the solution you'd like
A simple simple that only allows headers which is passed as an array of whitelisted headers

Describe alternatives you've considered
There doesn't seem to be any exhaustive solution as of now instead of creating my own filter.

Additional context
Add any other context or screenshots about the feature request here.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the existing request and response header filtering entry points and their tests in Spring Cloud Gateway. Determine how a whitelist of recognized headers should apply in both directions, then add coverage showing that unlisted headers are removed while listed headers remain.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, spring, spring-boot
Domain
api, backend, security
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.