views:

57

answers:

1

I'd like to use SSL for the post action on the login page of my MVC 1.0 app. I've seen some articles related to the [RequireSSL] attribute in ASP.NET MVC Futures. However, since this works using a redirect, I assume it's not an option (can't redirect a POST, correct?).

Ultimately, my goal is to get the Html.BeginForm method to render "https://..." as the form's action so that I can secure the information being posted (login info).

How have others handled this?

A: 

You could secure the form GET as well. If the form is retrieved with HTTPS, Html.BeginForm will automatically add https when rendering the form.

Darin Dimitrov
Thanks. I just arrived at that same conclusion. Don't know why I didn't think of that earlier.
goombaloon