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

fix: can not modify x-forwarded-host in proxy rewrite #8200

Conversation

monkeyDluffy6017
Copy link
Contributor

Description

fix can not modify x-forwarded-host in proxy rewrite

Checklist

  • I have explained the need for this PR and the problem it solves
  • I have explained the changes or the new features added to this PR
  • I have added tests corresponding to this change
  • I have updated the documentation to reflect this change
  • I have verified that this change is backward compatible (If not, please discuss on the APISIX mailing list first)

@monkeyDluffy6017 monkeyDluffy6017 marked this pull request as draft October 28, 2022 08:52
@monkeyDluffy6017 monkeyDluffy6017 marked this pull request as ready for review October 31, 2022 02:55
@monkeyDluffy6017 monkeyDluffy6017 changed the title bugfix: can not modify x-forwarded-host in proxy rewrite fix: can not modify x-forwarded-host in proxy rewrite Oct 31, 2022


=== TEST 45: set route(rewrite host)
--- config
Copy link
Member

Choose a reason for hiding this comment

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

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done




=== TEST 45: set route(rewrite host)
Copy link
Member

Choose a reason for hiding this comment

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

The title is incorrect. We don't rewrite the host

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

@@ -34,7 +34,61 @@ run_tests;

__DATA__

=== TEST 1: sanity
=== TEST 1: set route(rewrite host)
Copy link
Contributor

Choose a reason for hiding this comment

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

This case is samiliar to the one in proxy-rewrite-3.t?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

@spacewander spacewander merged commit 03e7606 into apache:master Nov 3, 2022
Liu-Junlin pushed a commit to Liu-Junlin/apisix that referenced this pull request Nov 4, 2022
hongbinhsu added a commit to fitphp/apix that referenced this pull request Nov 7, 2022
* upstream/master: (94 commits)
  test: add test cases for ai module (apache#8222)
  fix(ai): typo key name (apache#8232)
  docs:  update the docs of admin API  (apache#8191)
  Update standalone docs for change in SSL parameter (apache#8242)
  fix: can not modify x-forwarded-host in proxy rewrite (apache#8200)
  chore: export the set cert/key process so we can hook it (apache#8228)
  test: add cases of ai module (apache#8214)
  feat: add dafault value roundrobin for upstream_schema (apache#8180)
  docs: update limit plugin docs (apache#8154)
  dix remote_addr (apache#8210)
  fix(zipkin): send trace IDs with a reject sampling decision (apache#8099)
  docs: update hmac-auth doc (apache#8192)
  docs: update limit count plugin doc (apache#8196)
  docs: fix building apisix misled (apache#8189)
  fix: meta.filter in plugin doesn't work in response-rewrite plugin (apache#8162)
  feat: release 3.0 (apache#8179)
  docs: refactor admin api doc (apache#8145)
  docs: refactor health check doc (apache#8129)
  docs: protect-api.md typo, remove redundant braces. (apache#8139)
  feat: renew route lrucache when the routes change (apache#8157)
  ...
spacewander pushed a commit to spacewander/incubator-apisix that referenced this pull request Jan 28, 2023
Signed-off-by: spacewander <spacewanderlzx@gmail.com>
spacewander pushed a commit that referenced this pull request Jan 30, 2023
Signed-off-by: spacewander <spacewanderlzx@gmail.com>
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.

4 participants