IIS 7 Access Denied for local IP but not Localhost - visual-studio-2010

I've just started to experience this error. I'm developing MVC apps and using visual studio to deploy to my inetpub/wwwroot directory.
When i publish and hit the site at http://localhost the site works as expected.
When i hit the site using my IP address http://192.168.16.216 i get the following error
Unable to display page It has not been possible to display the page
you requested for the following reason: Access Denied Contact your
system administrator if you continue to experience difficulties.
I get this error on all browsers. I'm running IIS7 on Windows 7.
Any suggestions?

As I pointed out in my comment above:
Using your network IP means you'll be going out and back in again. Is your router configured to allow access to your machine on port 80?
It's likely that your company router isn't allowing access to your machine on port 80.

Related

How to solve google chrome "Failed to load resource: net::ERR_CONNECTION_REFUSED" issue in windows 10 when server is running on Ubuntu 18.04?

I am trying to run this project on Ubuntu 18.04 server. I am running both server and client on this machine. Then from windows 10 with port 9000 I am getting access to client in my chrome browser at http://localhost:8000/#/
The browser loads the project but the problem is I can't log into the website with trusted account and some other data do not get loaded . When I see browser console I see an error message saying:
Failed to load resource: net::ERR_CONNECTION_REFUSED
This is the server setting:
This is the client setting and putty setting to connect to client.
VPN has been used to connect to server via PuTTY.
The error message in browser:
Could anyone shed some light on this issue? Is it related to windows 10 or VPN or some other issues? I followed some steps from here https://www.ionos.com/digitalguide/hosting/technical-matters/err-connection-reset/
By default, the Flask development environment uses 127.0.0.1 (localhost), which restricts access to processes on the same host (except for VMs/containers, which aren't a factor here).
To access Flask from outside of localhost (e.g., from your Windows 10 machine), use the IP address 0.0.0.0. (You can pass it to run(), or via a command line option of the flask command.
However, do note the warnings about (not) using the development environment for production use.

http://hostname:5000/ runs on the machine but not remotely?

I created a console application (Asp.Net core Kestrel) which host a web site and copied it to a Windows Server. Browsing http://hostname:5000/ locally on the server works. However, it got This site can’t be reachedu _hostname_ refused to connect. when browsing the site on another machine.
I already created an inbound firewall rule.
I tried create a website in IIS on the server with port 5009. And the website can be remotely accessed.

ec2 hosted lamp site not visible from browser

I have setup an Amazon EC2 Ubuntu 16 server for the first time.
With the issued public IPv4 IP address I have ssh'ed into the server and installed a lamp stack.
However when I paste the IP address into my browser I get the following error:
Error
The requested URL could not be retrieved
Error: Access to the web site failed
Why you are seeing this:
The web filter could not display the requested site.
Possible reasons could be:
The web site denied you access, or the web filter received no reply from the site.
Internet connectivity issues might be preventing the website from sending or receiving traffic.
If this problem persists, please ask your administrator to:
Check access to the specific site - the HTTP error code is 504: Gateway Timeout.
From what I've seen online, I should see the default apache webpage from my server at this point.
Can anyone shed some light on this issue?

How can I access a webpage located inside a VM from the host machine's browser?

I am able to access the link http://localhost/men/tops-men/jackets-men.html successfully from my VM (configured using X2Go client).
IP Address of the VM: 10.146.106.204
I am also able to ping the VM successfully from my host machine (Windows).
The page that I am trying to access is a php page deployed on Apache Web Server.
However I am not able to do so from my Windows host machine.
I tried http://10.146.106.204/men/tops-men/jackets-men.html from my Windows machine but it did not work.
Do I have to configure something on my host machine or on my VM ?
Not sure what I am missing.
On VM check you can view http://10.146.106.204/men/tops-men/jackets-men.html
If not you need to configure the web server to listen on that IP (if you're running IIS this is under "bindings" in the right-hand side panel of IIS Manager).
On Host open a cmd window and check you can ping 10.146.106.204
If not check your firewall settings on the VM.
If neither of these 2 things help then you need to add more information about your setup to the question. Those are 2 very simple things you can do to diagnose 2 basic problems you might be having.
I was finally able to solve the problem based on this SO link: Unable to access magento site from anywhere but localhost
Updated the DB table core_config_data and updated the data by replacing http://localhost with http://ip-of-vm and then restarted the apache web server.

IIS 7 and ASP.Net MVC issue

This is a bit complex - so here we go.
I am developing a mobile web application using asp.net mvc and I need to test it locally on my iPhone. So far I have the first iteritaion of the site running on my local dev laptop. I created a virtual dir for the site under IIS 7 on the same machine. I deployed the site to that folder from VS2008. I open a browser and entered "" and the site cam up just fine. I am runnig a home network with locked down WIFI and both the laptip and my iPhone are on the network. So now I want to test with the iPhone but the site won't come up when browsing to "". I have another machine that is also on the network and I get this error message when attempting to browse to the site:
"Website (laptopname) is online but isn't responding to connection attempts"
I have a feeling that this has something to do with IIS setting and \ or application pools but have not been able to find anything relavent goolging. Any help appreciated.
There are some possibilities:
iPhone is not able to resolve your laptop by name. Try using the IP address of your computer in the URL instead.
The firewall on the laptop is blocking inbound connections from other machines. Check your firewall.
The IIS Website is configured with a host header localhost so it won't respond to requests to other hostnames. Check the binding for the Web site in the IIS Manager.
To eliminate possible network issues, you can create an ad hoc WiFi network on your PC and connect to that network to test.
Check that Allow Anonymous Access is set for the site
I suspect you are not alone, as I had this exact problem. I developed a small port opener I called "SharpProxy" that may make your local testing much easier.
Overview and instructions:
http://www.codefromjames.com/wordpress/?p=97
It's open source! Get code here: https://github.com/jocull/SharpProxy

Resources