locking to https

  • Thread starter Thread starter Tommy Martin
  • Start date Start date
T

Tommy Martin

I have a credit card page on my asp.net site and i want to make sure it only
runs on a secure connection. Is there a way to make a page not run or to
redirect it to the secure connection?

Thanks
Tommy
 
Never trust IIS to do what you can do yourself in code, unless you *really*
trust the people, IT guys, or script that set your IIS settings.

Ideally, you should set IIS correctly (as this will be faster on the
server), as well as code for redundancy. You can add this to your
page_load...

if (!Request.IsSecureConnection) Response.Redirect("https://secureserver");
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top