use https on asp.net application running on localhost - asp.net

I've created an asp.net web application with a web form called "Main.aspx" in it. I'm trying to run the application over https. Since I have no experiences with SSL, IIS etc. I googled how to achieve this but every solution didn't work for me.
I enabled SSL using the following steps: Enable SSL
My application is now running on https://localhost:59917/.
But if I start my application I get a Firefox error message: "Secure connection failed". So I followed the steps from Scott Gu's Blog Post but it didn't work neither.
Does anyone have experiences in SSL and ASP.net web applications and can help me out?

If you followed the instructions, you should have configured your website on the port 443.
You should configure the binding on port 59917

Related

Deploying ASP.Net MVC 5 application on a server with SSL

I've worked on an ASP.Net MVC 5 application using EF6. The project is ready for deployment and I've been told by the project manager that the project will be deployed on a server with IIS 7.0 using https/SSL. We will be running the server on our premises and the certificate has been purchased from GoDaddy. During development, I've not enabled SSL in Visual Studio project, and no certificate has been imported into Visual Studio.
My question are:
Do I have to enable SSL in Visual Studio and import SSL certificate before deployment, or I can publish the project as is, and enable SSL in IIS only?
When do we enable SSL in Visual Studio and import SSL certificate into it? My understanding is that it is done during development to enable testing on SSL, but I'm not sure if my understanding is correct.
If development has already been finished, is it still necessary to carry out the above scenario (enable SSL in Visual Studio and import SSL certificate in it)?
You can handle SSL in IIS- this is what my company currently does. You might want to look into the Url Rewrite Module in IIS. This enables your site to handle requests that are sent to http and https both and both types of request both end up forced going over ssl.
You can handle it on your server side by using your hosting cPanel/Plesk etc.Simply change all request the type on both http and https ,if you want to enable only https requests then configure it on only https .For more details how to configure and enable ssl on godaddy kindly view full details on the given link.
Link
This is how to configure an SSL web application in IIS Express.
After publishing SSL web application, just go to IIS Manager, right click on Sites, Add Website and fill in the Bindings section of the wizard like in the picture below (select https, select correct Port number from the SSL url shown in VS and the SSL certificate as well). Then you can browse to the published https web address rather than having to run in debug from VS.

ASP.NET MVC project Automaic route to a random location

I got an MVC project working in IISExpress. But when hosted in Azure app service and local host's IIS, I got 302 redirect from http://localhost//facebookapp/start to http://localhost/(S(gf3a4leuiyjafjltxdjabhae))/facebookapp/start, then get 404.
I also reported this here
I realize this must be a router problem, but I have no clue how to trace it down. Any help is appreciated!
Thanks!
Turns out the application I used the sample used localhost/facebookApp as the virtual directory, which certainly won't work if i blindly published to azure and IIS host.

How can I enforce IIS 8.5 Web Deploy to use SSL (HTTPS) Only

I've just set-up a website on Windows 2012 (IIS 8.5).
I'm using Visual Studio 2013, and I'm wanting to configure Web Deploy so that our developers can only deploy over SSL (HTTPS).
In the website settings I've configured the SSL for the site;
For the website binding, I only have HTTPS present;
However it seems that I can still publish using WebDeploy over HTTP and I can browse to the site using HTTP, even though the file in this case wasn't found.
My main requirement is to stop developers being able to publish over HTTP. How can I achieve this ?
I think you should try to redirect all HTTP Requests towards HTTPS
URL rewriting in IIS 7+:
http://blogs.msdn.com/b/kaushal/archive/2013/05/23/http-to-https-redirects-on-iis-7-x-and-higher.aspx
Make sure that you don't have another IIS web site (usually the Default Web Site) that binds to port 80 with All unsigned IP address and no host header. That kind of site is a "catch-all" site that gives you the 404.

How do I set up debugging under my local IIS for an MVC3 app?

My host is having issues getting my MVC3 app to work on their server, so I though I'd check it out myself. Until now I've been too busy developing under the built in server to worry about IIS, but today I tried my first deployment to the host with no joy. Then I tried one to my local IIS, with no joy. Then I tried telling VS to use IIS for debugging, to maybe resolve some local issues, with no joy.
What steps and configuration are required to use local IIS 7.5 to debug an MVC3 application?
EDIT: Going through a browser, after clearing up a permission problem for my Windows user on Temp ASP.NET Files, I now site with a I get a HTTP Error 403 (Forbidden), but the occassional basic auth login dialogue. Here I have tried a Forms auth user, my normal Windows user, and my Windows admin user, all to no avail.
When I try and debug under VS, I get a 500, internal error.
THE PLOT THICKENS: When I enable directory browsing on the site, I get a proper directory listing for the site root url. This suggests the the MVC3 routing is not working, but why not?
If you're getting a directory listing that means there's not a default file set (for IIS6). It usually means the request wasn't routed to IIS to deal with. thing are slightly different with II7 & it's integrated pipeline.
Simon

ASP: integrating HTTPS

I am trying to integrate https on my web application. This link describes what should I do in IIS. Is there any other thing i should do in my web application regarding web.config? seriously I have no idea at all on how to do this. Any support would be appreciated.
Regards.
Nope all you need to do is get a certificate and install it in IIS, bind your host to port 443 and you should be good to go. Your app should run as-is on there.
Good resource here

Resources