Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Customer headers are removed with internationalisation #21507

Closed
tomevans18 opened this issue Jan 25, 2021 · 4 comments · Fixed by #22500
Closed

Customer headers are removed with internationalisation #21507

tomevans18 opened this issue Jan 25, 2021 · 4 comments · Fixed by #22500
Assignees
Milestone

Comments

@tomevans18
Copy link

What version of Next.js are you using?

10.0.3

What version of Node.js are you using?

15.3.0

What browser are you using?

Chrome

What operating system are you using?

macOS (intel)

How are you deploying your application?

Vercel

Describe the Bug

Within the next.config.js, if you have customer headers and deploy to Vercel, these headers are added to the response.
When you then add internationalisation some of these custom headers are removed.

Observed headers being removed:

  • X-Frame-Options
  • X-XSS-Protection
  • X-Robots-Tag

Expected Behavior

Custom headers should be populated in the response when using internationalisation.

To Reproduce

  1. Create a project with customer headers:
  • X-Frame-Options
  • X-XSS-Protection
  • X-Robots-Tag
  1. Deploy to Vercel and observe the custom headers within the response

  2. Add internationalisation to your project

  3. Deploy to Vercel

  4. Observe the above noted custom headers have been removed

@tomevans18 tomevans18 added the bug Issue was opened via the bug report template. label Jan 25, 2021
@tomevans18 tomevans18 changed the title Customer headers being removed with internationalisation Customer headers are removed with internationalisation Jan 25, 2021
@timneutkens timneutkens added kind: bug and removed bug Issue was opened via the bug report template. labels Jan 27, 2021
@timneutkens timneutkens added this to the 10.x.x milestone Jan 27, 2021
@Timer Timer removed this from the 10.x.x milestone Jan 27, 2021
@tomevans18
Copy link
Author

@Timer I noticed you removed the release milestone, is there a particular reason for this or simply workload capacity related?
I'm just trying to track this as its important from a security POV.
Many thanks!

@ijjk
Copy link
Member

ijjk commented Feb 22, 2021

Hi @tomevans18 can you provide a minimal reproduction where you are seeing this behavior? I'm not able to reproduce this on the latest version of Next.js v10.0.7

@ijjk ijjk added the please add a complete reproduction The issue lacks information for further investigation label Feb 22, 2021
@Timer Timer added this to the 10.x.x milestone Feb 22, 2021
@tomevans18
Copy link
Author

Hi @ijjk,

I have given you access to a repo where this is happening.
I am needing to make it private due to company code.

Many thanks

@ijjk ijjk added kind: story and removed kind: bug please add a complete reproduction The issue lacks information for further investigation labels Feb 24, 2021
@ijjk ijjk self-assigned this Feb 24, 2021
@kodiakhq kodiakhq bot closed this as completed in #22500 Feb 24, 2021
kodiakhq bot pushed a commit that referenced this issue Feb 24, 2021
This mentions how locale routes are transformed when `locale: false` is not used to explain why regex routes might not match with i18n. 

Closes: #21507
@Timer Timer modified the milestones: 10.x.x, iteration 17 Feb 24, 2021
@balazsorban44
Copy link
Member

This issue has been automatically locked due to no recent activity. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you.

@vercel vercel locked as resolved and limited conversation to collaborators Jan 28, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants