3 Replies - 1042 Views - Last Post: 27 October 2016 - 08:18 AM

#1 Coding in the name of  Icon User is offline

  • D.I.C Regular

Reputation: 67
  • View blog
  • Posts: 291
  • Joined: 07-July 10

Can access website inside network but not outside

Posted 24 October 2016 - 04:05 PM

I'm running IIS 8 on a server with a single network interface that is overloaded with several IP addresses. I'm running three different websites and they're bound to these different IP addresses. The router does WAN IP aliasing (IPCP) so each of the private IP addresses maps to a different public IP address, and I've done the port forwarding for ports 80 and 443 and the address mapping for these.

We've used the DNS records on our hosting provider's site to point to our router's range of public addresses so that they are different subdomains of our main domain. And we've got two different SSL certificates installed for two of the websites. For these websites we've setup bindings for http to port 80 and https to port 443 on one private IP for each site.

The first website we did this for has worked out great, but the second one is only accessible from behind our router. We can access it with the public URL that we configured on our provider's DNS but outside the network the URL times out.

I've checked that both websites have their configs the same in the bits that are relevant and the certificates were installed in the same way and seem to be ok. The firewall is ok. We're using a DrayTek Vigor 2920n. Our main website which has no SSL binding works fine, the first website we configured for SSL works fine, but this next one doesn't, unless you're on our network.

Any advice would be much appreciated, tell me if there's more information you need. Thanks.

This post has been edited by Coding in the name of: 24 October 2016 - 04:06 PM


Is This A Good Question/Topic? 0
  • +

Replies To: Can access website inside network but not outside

#2 ArtificialSoldier  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 1769
  • View blog
  • Posts: 5,646
  • Joined: 15-January 14

Re: Can access website inside network but not outside

Posted 24 October 2016 - 04:31 PM

It sounds like an issue with the router if things work fine from inside your network, so I would focus there (although it may be a misconfiguration with IIS that looks like a router issue). For example, make sure that outbound NAT is configured so that the web server will respond on the appropriate IP also (so that requests to any site don't all come from the same IP).
Was This Post Helpful? 0
  • +
  • -

#3 no2pencil  Icon User is online

  • Professor Snuggly Pants
  • member icon

Reputation: 6541
  • View blog
  • Posts: 30,615
  • Joined: 10-May 07

Re: Can access website inside network but not outside

Posted 24 October 2016 - 04:38 PM

Also verify that your ISP is not blocking the standard port 80/443 for webservers.

Does the request time out, or does it immediately return empty? If not timing out, what does the server logs say?
Was This Post Helpful? 0
  • +
  • -

#4 Coding in the name of  Icon User is offline

  • D.I.C Regular

Reputation: 67
  • View blog
  • Posts: 291
  • Joined: 07-July 10

Re: Can access website inside network but not outside

Posted 27 October 2016 - 08:18 AM

I get nothing in the failed request tracing when I try to access the website. It can't be the ISP blocking the ports we've been hosting these websites for several months with no problems. I'm trying to roll back the web config changes I've made now. I'm keeping the SSL certificate installed and I'm keeping the binding on the problem site but I'm removing the extra security stuff from the Web.config. No joy yet.

I tried toggling Join NAT IP Pool for the site's WAN IP in the multi-WAN settings but the only effect this has is knocking out web access for our whole network and it doesn't make the website accessible from outside.

<?xml version="1.0" encoding="utf-8"?>
<!--
  For more information on how to configure your ASP.NET application, please visit
  http://go.microsoft.com/fwlink/?LinkId=301880
  -->
<configuration>
  <configSections>
    <!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 -->
    <section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
    <sectionGroup name="elmah">
      <section name="security" requirePermission="false" type="Elmah.SecuritySectionHandler, Elmah" />
      <section name="errorLog" requirePermission="false" type="Elmah.ErrorLogSectionHandler, Elmah" />
      <section name="errorMail" requirePermission="false" type="Elmah.ErrorMailSectionHandler, Elmah" />
      <section name="errorFilter" requirePermission="false" type="Elmah.ErrorFilterSectionHandler, Elmah" />
    </sectionGroup>
  </configSections>
  <connectionStrings>
    <add name="EPCConnection" connectionString="server=---------;uid=------;pwd=-------;database=----;" providerName="MySql.Data.MySqlClient" />
  </connectionStrings>
  <appSettings>
    <add key="webpages:Version" value="3.0.0.0" />
    <add key="webpages:Enabled" value="false" />
    <add key="ClientValidationEnabled" value="true" />
    <add key="UnobtrusiveJavascriptEnabled" value="true" />
    <add key="ImageExtensions" value=".jpg;.png" />
    <add key="DocumentExtensions" value=".pdf;.xml" />
    <add key="elmah.mvc.disableHandler" value="false" />
    <add key="elmah.mvc.disableHandleErrorFilter" value="false" />
    <add key="elmah.mvc.requiresAuthentication" value="true" />
    <add key="elmah.mvc.IgnoreDefaultRoute" value="false" />
    <add key="elmah.mvc.allowedRoles" value="ChataAdmin" />
    <add key="elmah.mvc.allowedUsers" value="*" />
    <add key="elmah.mvc.route" value="elmah" />
    <add key="elmah.mvc.UserAuthCaseSensitive" value="true" />
  </appSettings>
  <system.web>
    <compilation targetFramework="4.5.2" />
    <httpRuntime targetFramework="4.5.2" maxRequestLength="500000000" />
    <authentication mode="None" />
    <membership defaultProvider="MySQLMembershipProvider">
      <providers>
        <remove name="MySQLMembershipProvider" />
        <add name="MySQLMembershipProvider" type="MySql.Web.Security.MySQLMembershipProvider, MySql.Web, Version=6.9.9.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" connectionStringName="LocalMySqlServer" enablePasswordRetrieval="false" enablePasswordReset="true" requiresQuestionAndAnswer="true" applicationName="/" requiresUniqueEmail="false" passwordFormat="Clear" maxInvalidPasswordAttempts="5" minRequiredPasswordLength="7" minRequiredNonalphanumericCharacters="1" passwordAttemptWindow="10" passwordStrengthRegularExpression="" />
      </providers>
    </membership>
    <profile defaultProvider="MySQLProfileProvider">
      <providers>
        <remove name="MySQLProfileProvider" />
        <add name="MySQLProfileProvider" type="MySql.Web.Profile.MySQLProfileProvider, MySql.Web, Version=6.9.9.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" connectionStringName="LocalMySqlServer" applicationName="/" />
      </providers>
    </profile>
    <roleManager defaultProvider="MySQLRoleProvider">
      <providers>
        <remove name="MySQLRoleProvider" />
        <add name="MySQLRoleProvider" type="MySql.Web.Security.MySQLRoleProvider, MySql.Web, Version=6.9.9.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" connectionStringName="LocalMySqlServer" applicationName="/" />
      </providers>
    </roleManager>
    <siteMap defaultProvider="MySqlSiteMapProvider">
      <providers>
        <remove name="MySqlSiteMapProvider" />
        <add name="MySqlSiteMapProvider" type="MySql.Web.SiteMap.MySqlSiteMapProvider, MySql.Web, Version=6.9.9.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" connectionStringName="LocalMySqlServer" applicationName="/" />
      </providers>
    </siteMap>
    <webParts>
      <personalization defaultProvider="MySQLPersonalizationProvider">
        <providers>
          <remove name="MySQLPersonalizationProvider" />
          <add name="MySQLPersonalizationProvider" type="MySql.Web.Personalization.MySqlPersonalizationProvider, MySql.Web, Version=6.9.9.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" connectionStringName="LocalMySqlServer" applicationName="/" />
        </providers>
      </personalization>
    </webParts>
    <httpModules>
      <add name="ErrorLog" type="Elmah.ErrorLogModule, Elmah" />
      <add name="ErrorMail" type="Elmah.ErrorMailModule, Elmah" />
      <add name="ErrorFilter" type="Elmah.ErrorFilterModule, Elmah" />
    </httpModules>
  </system.web>
  <system.net>
    <mailSettings>
      <smtp deliveryMethod="Network" deliveryFormat="SevenBit" from="[email protected]">
        <network host="smtp.livemail.co.uk" port="587" defaultCredentials="false" userName="------" password="-------" enableSsl="false" />
      </smtp>
    </mailSettings>
  </system.net>
  <system.webServer>
    <modules>
      <add name="ErrorLog" type="Elmah.ErrorLogModule, Elmah" preCondition="managedHandler" />
      <add name="ErrorMail" type="Elmah.ErrorMailModule, Elmah" preCondition="managedHandler" />
      <add name="ErrorFilter" type="Elmah.ErrorFilterModule, Elmah" preCondition="managedHandler" />
    </modules>
    <httpErrors errorMode="DetailedLocalOnly" existingResponse="Replace">
      <clear />
      <error statusCode="400" path="/Error/400.html" responseMode="ExecuteURL" />
      <error statusCode="403" path="/Error/403.html" responseMode="ExecuteURL" />
      <error statusCode="404" path="/Error/404.html" responseMode="ExecuteURL" />
      <error statusCode="500" path="/Error/500.html" responseMode="ExecuteURL" />
    </httpErrors>
    <validation validateIntegratedModeConfiguration="false" />
    <httpProtocol>
      <customHeaders>
        <remove name="Strict-Transport-Security" />
      </customHeaders>
    </httpProtocol>
  </system.webServer>
  <runtime>
    <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
      <dependentAssembly>
        <assemblyIdentity name="Microsoft.Owin.Security" publicKeyToken="31bf3856ad364e35" />
        <bindingRedirect oldVersion="0.0.0.0-3.0.1.0" newVersion="3.0.1.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="Microsoft.Owin.Security.OAuth" publicKeyToken="31bf3856ad364e35" />
        <bindingRedirect oldVersion="0.0.0.0-3.0.1.0" newVersion="3.0.1.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="Microsoft.Owin.Security.Cookies" publicKeyToken="31bf3856ad364e35" />
        <bindingRedirect oldVersion="0.0.0.0-3.0.1.0" newVersion="3.0.1.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="Microsoft.Owin" publicKeyToken="31bf3856ad364e35" />
        <bindingRedirect oldVersion="0.0.0.0-3.0.1.0" newVersion="3.0.1.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="Newtonsoft.Json" culture="neutral" publicKeyToken="30ad4fe6b2a6aeed" />
        <bindingRedirect oldVersion="0.0.0.0-9.0.0.0" newVersion="9.0.0.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="System.Web.Optimization" publicKeyToken="31bf3856ad364e35" />
        <bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="1.1.0.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="WebGrease" publicKeyToken="31bf3856ad364e35" />
        <bindingRedirect oldVersion="0.0.0.0-1.6.5135.21930" newVersion="1.6.5135.21930" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="System.Web.Helpers" publicKeyToken="31bf3856ad364e35" />
        <bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="System.Web.Mvc" publicKeyToken="31bf3856ad364e35" />
        <bindingRedirect oldVersion="0.0.0.0-5.2.3.0" newVersion="5.2.3.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="System.Web.WebPages" publicKeyToken="31bf3856ad364e35" />
        <bindingRedirect oldVersion="0.0.0.0-3.0.0.0" newVersion="3.0.0.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="Antlr3.Runtime" publicKeyToken="eb42632606e9261f" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-3.5.0.2" newVersion="3.5.0.2" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="MySql.Data" publicKeyToken="c5687fc88969c44d" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-6.9.9.0" newVersion="6.9.9.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="log4net" publicKeyToken="669e0ddf0bb1aa2a" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-1.2.15.0" newVersion="1.2.15.0" />
      </dependentAssembly>
    </assemblyBinding>
  </runtime>
  <entityFramework>
    <defaultConnectionFactory type="System.Data.Entity.Infrastructure.LocalDbConnectionFactory, EntityFramework">
      <parameters>
        <parameter value="mssqllocaldb" />
      </parameters>
    </defaultConnectionFactory>
    <providers>
      <provider invariantName="System.Data.SqlClient" type="System.Data.Entity.SqlServer.SqlProviderServices, EntityFramework.SqlServer" />
      <provider invariantName="MySql.Data.MySqlClient" type="MySql.Data.MySqlClient.MySqlProviderServices, MySql.Data.Entity.EF6, Version=6.9.9.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d"></provider>
    </providers>
  </entityFramework>
  <system.data>
    <DbProviderFactories>
      <remove invariant="MySql.Data.MySqlClient" />
      <add name="MySQL Data Provider" invariant="MySql.Data.MySqlClient" description=".Net Framework Data Provider for MySQL" type="MySql.Data.MySqlClient.MySqlClientFactory, MySql.Data, Version=6.9.9.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" />
    </DbProviderFactories>
  </system.data>
  <elmah></elmah>
  <system.codedom>
    <compilers>
      <compiler language="c#;cs;csharp" extension=".cs" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.CSharpCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=1.0.2.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" warningLevel="4" compilerOptions="/langversion:6 /nowarn:1659;1699;1701" />
      <compiler language="vb;vbs;visualbasic;vbscript" extension=".vb" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.VBCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=1.0.2.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" warningLevel="4" compilerOptions="/langversion:14 /nowarn:41008 /define:_MYTYPE=\"Web\" /optionInfer+" />
    </compilers>
  </system.codedom>
</configuration>


Here's how it looks when I try to load the site externally. The loading bar stops at this point for several seconds until I get shown just a blank page.

Posted Image
Posted Image

This post has been edited by Coding in the name of: 28 October 2016 - 06:52 AM

Was This Post Helpful? 0
  • +
  • -

Page 1 of 1