Nginx Reverse Proxy DO NOT PASS Authorization

I set up nginx asking for basic auth for some IP blocks, here is the post: Nginx 特定 IP 需要认证.

But for some products, they read Authorization header to identify client as users. If so, these two different auth would be mixed and the backend application works bad.

To solve this, add this line to proxy:

Nginx Reverse Proxy DO NOT PASS Authorization by @sskaje: https://sskaje.me/2017/01/nginx-reverse-proxy-pass-authorization/