You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by GitBox <gi...@apache.org> on 2022/10/28 03:24:15 UTC

[GitHub] [apisix] wangfeng22 opened a new issue, #8195: bug: proxy-rewrite X-Forwarded-For doesn't work.

wangfeng22 opened a new issue, #8195:
URL: https://github.com/apache/apisix/issues/8195

   ### Current Behavior
   
   I have set proxy-rewrite X-Forwarded-For header, but It's still invaild.
   
   ### Expected Behavior
   
   _No response_
   
   ### Error Logs
   
   _No response_
   
   ### Steps to Reproduce
   
   1. Create a route with the X-Forwarded-For of headers rewrited.
   2. Send a request through this route, and watch the back-end.
   
   ### Environment
   
   - APISIX version (run `apisix version`): 2.13.2
   - Operating system (run `uname -a`):
   - OpenResty / Nginx version (run `openresty -V` or `nginx -V`):
   - etcd version, if relevant (run `curl http://127.0.0.1:9090/v1/server_info`):
   - APISIX Dashboard version, if relevant:
   - Plugin runner version, for issues related to plugin runners:
   - LuaRocks version, for installation issues (run `luarocks --version`):
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix] monkeyDluffy6017 commented on issue #8195: bug: proxy-rewrite X-Forwarded-For doesn't work.

Posted by GitBox <gi...@apache.org>.
monkeyDluffy6017 commented on issue #8195:
URL: https://github.com/apache/apisix/issues/8195#issuecomment-1294781903

   @wangfeng22 Try to fix like this: https://github.com/apache/apisix/pull/4260


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix] zuiyangqingzhou commented on issue #8195: bug: proxy-rewrite X-Forwarded-For doesn't work.

Posted by GitBox <gi...@apache.org>.
zuiyangqingzhou commented on issue #8195:
URL: https://github.com/apache/apisix/issues/8195#issuecomment-1294524384

   > @monkeyDluffy6017 yes, I will try to figure it out this weekend.
   
   @wangfeng22   you can try this: https://github.com/apache/apisix/discussions/5091     


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix] Hazel6869 commented on issue #8195: bug: proxy-rewrite X-Forwarded-For doesn't work.

Posted by GitBox <gi...@apache.org>.
Hazel6869 commented on issue #8195:
URL: https://github.com/apache/apisix/issues/8195#issuecomment-1294483712

   > > @wangfeng22 I found 'X-Forwarded-For' has been configured in the file nginx.conf, so you can't change it. πŸ˜… ![image](https://user-images.githubusercontent.com/30279880/198499987-19a1e2bb-252d-4069-945a-99d1e31dc9a2.png)
   > 
   > But you can change X-Forwarded-Proto, X-Forwarded-Host..., is that true?
   
   I also can't, this is not allowed.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix] Hazel6869 commented on issue #8195: bug: proxy-rewrite X-Forwarded-For doesn't work.

Posted by GitBox <gi...@apache.org>.
Hazel6869 commented on issue #8195:
URL: https://github.com/apache/apisix/issues/8195#issuecomment-1294406525

   @wangfeng22  Hi, can you give me your  related curl?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix] wangfeng22 commented on issue #8195: bug: proxy-rewrite X-Forwarded-For doesn't work.

Posted by GitBox <gi...@apache.org>.
wangfeng22 commented on issue #8195:
URL: https://github.com/apache/apisix/issues/8195#issuecomment-1294436594

   
   
   
   
   > @wangfeng22 I found 'X-Forwarded-For' has been configured in the file nginx.conf, so you can't change it. πŸ˜… ![image](https://user-images.githubusercontent.com/30279880/198499987-19a1e2bb-252d-4069-945a-99d1e31dc9a2.png)
   
   But you can change X-Forwarded-Proto, X-Forwarded-Host..., is that true?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix] wangfeng22 commented on issue #8195: bug: proxy-rewrite X-Forwarded-For doesn't work.

Posted by GitBox <gi...@apache.org>.
wangfeng22 commented on issue #8195:
URL: https://github.com/apache/apisix/issues/8195#issuecomment-1294414220

   > @wangfeng22 Hi, can you give me your related curl, I'll check it out for you.
   1. Create a random route, set proxy-rewrite X-Forwarded-For header, and watch the back-end.
   ```
   curl --location --request GET 'http://test.test/api' \
   --header 'X-Forwarded-For: 1.1.1.1'
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix] Hazel6869 commented on issue #8195: bug: proxy-rewrite X-Forwarded-For doesn't work.

Posted by GitBox <gi...@apache.org>.
Hazel6869 commented on issue #8195:
URL: https://github.com/apache/apisix/issues/8195#issuecomment-1294415888

   @wangfeng22  Can you give me the curl for configure proxy-rewrite plugin


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix] monkeyDluffy6017 commented on issue #8195: bug: proxy-rewrite X-Forwarded-For doesn't work.

Posted by GitBox <gi...@apache.org>.
monkeyDluffy6017 commented on issue #8195:
URL: https://github.com/apache/apisix/issues/8195#issuecomment-1294421179

   Would you like to submit a pr to fix this problem? @wangfeng22 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix] Hazel6869 commented on issue #8195: bug: proxy-rewrite X-Forwarded-For doesn't work.

Posted by GitBox <gi...@apache.org>.
Hazel6869 commented on issue #8195:
URL: https://github.com/apache/apisix/issues/8195#issuecomment-1294418682

   @wangfeng22 Hold on, let me give you an example.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix] wangfeng22 closed issue #8195: bug: proxy-rewrite X-Forwarded-For doesn't work.

Posted by GitBox <gi...@apache.org>.
wangfeng22 closed issue #8195: bug: proxy-rewrite X-Forwarded-For doesn't work.
URL: https://github.com/apache/apisix/issues/8195


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix] wangfeng22 commented on issue #8195: bug: proxy-rewrite X-Forwarded-For doesn't work.

Posted by GitBox <gi...@apache.org>.
wangfeng22 commented on issue #8195:
URL: https://github.com/apache/apisix/issues/8195#issuecomment-1294438944

   @monkeyDluffy6017 yes, I will try to figure it out this weekend.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix] wangfeng22 commented on issue #8195: bug: proxy-rewrite X-Forwarded-For doesn't work.

Posted by GitBox <gi...@apache.org>.
wangfeng22 commented on issue #8195:
URL: https://github.com/apache/apisix/issues/8195#issuecomment-1294416090

   > @wangfeng22 Can you give me the curl for configure proxy-rewrite plugin
   ```
   {
     "uri": "/*",
     "name": "εΌ€ε‘ζœΊζ΅‹θ―•θ·―η”±",
     "methods": [
       "GET",
       "POST",
       "PUT",
       "DELETE",
       "PATCH",
       "HEAD",
       "OPTIONS",
       "CONNECT",
       "TRACE"
     ],
     "host": "test.test",
     "plugins": {
       "proxy-rewrite": {
         "headers": {
           "X-Forwarded-For": "AAAA"
         }
       }
     },
     "upstream_id": "431751431687504807",
     "status": 1
   }
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix] wangfeng22 commented on issue #8195: bug: proxy-rewrite X-Forwarded-For doesn't work.

Posted by GitBox <gi...@apache.org>.
wangfeng22 commented on issue #8195:
URL: https://github.com/apache/apisix/issues/8195#issuecomment-1294455792

   > @monkeyDluffy6017 yes, I will try to figure it out this weekend.
   
   @monkeyDluffy6017 I think I don't know how to fix it.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix] zuiyangqingzhou commented on issue #8195: bug: proxy-rewrite X-Forwarded-For doesn't work.

Posted by GitBox <gi...@apache.org>.
zuiyangqingzhou commented on issue #8195:
URL: https://github.com/apache/apisix/issues/8195#issuecomment-1294523747

   > @monkeyDluffy6017 yes, I will try to figure it out this weekend.
   
   you can try this: https://github.com/apache/apisix/discussions/5091


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org