Вопрос

I just need to create a rule in IIS (7.5) to redirect all my traffic for http to https. There are two potential ways of doing it. First is by installing and configuring URL rewrite module. Other one is by endabling httpRedirect. I am not sure what are the difference in these two and if any one is better than other?

Это было полезно?

Решение

Not sure which approach is better, but I always use the RequireHttpsAttribute on an ActionResult so I have the control in my MVC application. When I'm moving the application to another server I don't have to (re)configure IIS.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top