0

We're running Node.js/express.js on Azure WebApp with SSL binding. It seems like the req.protocol always returns http.

Is there a way to get the original protocol, i.e. http/https according to the original request?

Guy Korland
  • 9,139
  • 14
  • 59
  • 106
  • 1
    http://stackoverflow.com/a/16042648/893780 – robertklep Aug 25 '15 at 10:53
  • @robertklep is that the way Azure acts or should the client add these header? – Guy Korland Aug 25 '15 at 13:10
  • Azure will probably set one of those headers (most likely the `Front-End-Https` one) to indicate the original protocol. I don't have experience with Azure myself so you have to do a bit of debugging to find out exactly which header you need to check. – robertklep Aug 25 '15 at 13:21
  • Thanks due to your answer I found this answer http://stackoverflow.com/a/15139339/593425 they are using 'x-arr-ssl' – Guy Korland Aug 25 '15 at 13:34

0 Answers0