I have created a asp.net mvc web api project. I am passing sensitive data to a web api application. The web api application I created requires ssl. When I call the web api using https I would like to verify that the information is encrypted from end to end. Is there a way to do this or am I just being paranoid.
1 Answer
You can configure IIS to require SSL (and IIS will perform redirections on your behalf) but the main way is by doing this:
if( Request.IsSecureConnection ) {
// Using SSL or TLS.
}
1 Comment
siva.k
You can also decorate controllers and/or actions with
[RequireHttps] and http requests will automatically be redirected to https before being allowed to execute the controller/action.