I'm trying to add some custom http headers for the authentication from mobile client, like
{'MOBILE_KEY' => 'xxx', 'MOBILE_SIGNATURE' => 'yyy'}
when I work with webrick/thin/mongrel in development, it works fine, but when I deployed it to the production server with nginx+passenger, the custom headers are removed, why? and what can I do?
There is a directive in nginx
that says to ignore headers with a '_' in the name.
http://nginx.org/en/docs/http/ngx_http_core_module.html#underscores_in_headers
That helped me, but rewriting your software to use the X- format may be even better.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With