2

I have a nodeJs front end on one domain and a rest back end server on another domain.

I would like to be able to perform ajax requests from the front to the back. So, i intend to use a reverse proxy for that, in order to bypass the same origin policy restriction.

My back end Rest server will be secured with Basic auth or OAuth. I would like to know, if i use node-http-proxy if it is possible to send an Authorization header in the http request before proxying it, and how.

Thanks a lot.

rico
  • 1,843
  • 2
  • 24
  • 41

1 Answers1

2

You have plenty of ways to accomplish that:

Best Regards,

eveiga
  • 206
  • 3
  • 9
  • I don't want to set the header on the ajax request, because i don't want to let see the credentials with tools like Firebug. I want to set the header on server side, not on client side. That's why i want also to use a proxy, for security. What i would like to do is setting the Authorization header on server side just before proxing it. – rico Apr 16 '12 at 13:42