No protocol binding matches the given address. Protocol bindings are configured at the Site level in IIS or WAS configuration.

답변됨 No protocol binding matches the given address. Protocol bindings are configured at the Site level in IIS or WAS configuration.

  • 2012年3月29日 5:46
     
     

    Hi,

    I have hosted ListService application sample available with SyncFramework Toolkit in IIS - windows 7. My host address is mapped to public via port forwarding and iam able to access the site within my intranet. But when i try to access it from internet it shows an exception as follows.

    My Web.Config is as below:

     <?xml version="1.0"?>

    <configuration>
    <configSections>
    <sectionGroup name="system.web.extensions" type="System.Web.Configuration.SystemWebExtensionsSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
    <sectionGroup name="scripting" type="System.Web.Configuration.ScriptingSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
    <section name="scriptResourceHandler" type="System.Web.Configuration.ScriptingScriptResourceHandlerSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
    <sectionGroup name="webServices" type="System.Web.Configuration.ScriptingWebServicesSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
    <section name="jsonSerialization" type="System.Web.Configuration.ScriptingJsonSerializationSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="Everywhere"/>
    <section name="profileService" type="System.Web.Configuration.ScriptingProfileServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
    <section name="authenticationService" type="System.Web.Configuration.ScriptingAuthenticationServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
    <section name="roleService" type="System.Web.Configuration.ScriptingRoleServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/></sectionGroup></sectionGroup></sectionGroup>
      </configSections>
      <appSettings/>

    <connectionStrings>
    <!--<add name="ListDbConnectionString" connectionString="Data Source=.;Initial Catalog=listdb;Persist Security Info=True;User ID=KAMAppUser;Password=5pec1Al153;MultipleActiveResultSets=True;" />-->
    <add name="ListDbConnectionString" connectionString="Data Source=QBADMIN-PC\SQLEXPRESS;Initial Catalog=listdb;Integrated Security=true;"/>
    </connectionStrings>
    <system.serviceModel>
        <services >


        </services>


    </system.serviceModel>
    <system.web>
    <!-- 
                Set compilation debug="true" to insert debugging 
                symbols into the compiled page. Because this 
                affects performance, set this value to true only 
                during development.
            -->
    <compilation debug="true">
    <assemblies>
    <add assembly="System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
    <add assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
    <add assembly="System.Xml.Linq, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
    <add assembly="System.Data.DataSetExtensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
          </assemblies>
        </compilation>
    <!--
                The <authentication> section enables configuration 
                of the security authentication mode used by 
                ASP.NET to identify an incoming user. 
            -->
    <authentication mode="None"/>
    <!--
                The <customErrors> section enables configuration 
                of what to do if/when an unhandled error occurs 
                during the execution of a request. Specifically, 
                it enables developers to configure html error pages 
                to be displayed in place of a error stack trace.    -->
    <customErrors mode="Off">
    <!--<error statusCode="403" redirect="NoAccess.htm" />
                <error statusCode="404" redirect="FileNotFound.htm" />-->
    </customErrors>
    <identity impersonate="false"/>
    <pages>
    <controls>
    <add tagPrefix="asp" namespace="System.Web.UI" assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
    <add tagPrefix="asp" namespace="System.Web.UI.WebControls" assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/></controls></pages>
    <httpHandlers>
    <remove verb="*" path="*.asmx"/>
    <add verb="*" path="*.asmx" validate="false" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
    <add verb="*" path="*_AppService.axd" validate="false" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
    <add verb="GET,HEAD" path="ScriptResource.axd" validate="false" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/></httpHandlers>
    <httpModules>
    <add name="ScriptModule" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
        </httpModules>
      </system.web>
    <!-- 
            The system.webServer section is required for running ASP.NET AJAX under Internet
            Information Services 7.0.  It is not necessary for previous version of IIS.
        -->
    <system.webServer>
    <directoryBrowse enabled="true"/>
    <validation validateIntegratedModeConfiguration="false"/>
    <modules>
    <remove name="ScriptModule"/>
    <add name="ScriptModule" preCondition="managedHandler" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
        </modules>

    <handlers>
    <remove name="WebServiceHandlerFactory-Integrated"/>
    <remove name="ScriptHandlerFactory"/>
    <remove name="ScriptHandlerFactoryAppServices"/>
    <remove name="ScriptResource"/>
    <add name="ScriptHandlerFactory" verb="*" path="*.asmx" preCondition="integratedMode" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
    <add name="ScriptHandlerFactoryAppServices" verb="*" path="*_AppService.axd" preCondition="integratedMode" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
    <add name="ScriptResource" verb="GET,HEAD" path="ScriptResource.axd" preCondition="integratedMode" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
        </handlers>
      </system.webServer>

    <system.diagnostics>
    <sources>
    <source name="System.ServiceModel" switchValue="Information, ActivityTracing" propagateActivity="true">
    <listeners>
    <add name="traceListener" type="System.Diagnostics.XmlWriterTraceListener" initializeData="c:\log\Traces.svclog"/>
    </listeners>
    </source>
    </sources>
    </system.diagnostics>
    <system.codedom>
    <compilers>
    <compiler language="c#;cs;csharp" extension=".cs" type="Microsoft.CSharp.CSharpCodeProvider, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" warningLevel="4">
    <providerOption name="CompilerVersion" value="v3.5"/>
    <providerOption name="WarnAsError" value="false"/></compiler></compilers></system.codedom>
    <runtime>
    <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1" appliesTo="v2.0.50727">
    <dependentAssembly>
    <assemblyIdentity name="System.Web.Extensions" publicKeyToken="31bf3856ad364e35"/>
    <bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="3.5.0.0"/></dependentAssembly>
    <dependentAssembly>
    <assemblyIdentity name="System.Web.Extensions.Design" publicKeyToken="31bf3856ad364e35"/>
    <bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="3.5.0.0"/></dependentAssembly></assemblyBinding>
      </runtime>


    </configuration>

すべての返信

  • 2012年3月29日 6:12
    モデレータ
     
     
  • 2012年3月29日 7:05
     
     

    This is a Sync Service and Iam new to this syncservice. Actually this service works fine in my intranet without any endpoints in Web.Config.

    i think by default the endpoint resolving is taking place from svc file. 

    Following is the SVC File :

    <%@ ServiceHost Language="CS" Debug="true" Service="DefaultScope.DefaultScopeSyncService" CodeBehind="DefaultScopeSyncService.SVC.CS" Factory="Microsoft.Synchronization.Services.SyncServiceHostFactory, Microsoft.Synchronization.Services,Version=1.0.0.0, Culture=neutral" %>


  • 2012年3月29日 7:25
    モデレータ
     
     

    how are you browsing it from your intranet?

    svc file has nothing to do with endpoints, it tells where the code resides. The sync service is a WCF service. just address what the error is telling you about binding and you should be fine.

  • 2012年3月29日 7:45
     
     

    the intranet address is like this :http://10.3.0.94:2800/ListService/DefaultScopeSyncService.svc/$syncscopes

    This is working perfectly without any endpoints in config file. so if it need to be access from outside do i need to specify the endpoints .

    if so what would be my binding configuration for this particular syncservice.

    Thanks in advance

    Bijo Abraham

  • 2012年3月29日 8:07
    モデレータ
     
     

    you might want to try the solutions in the link i posted above.

    maybe try the host header approach first.

  • 2012年3月30日 8:45
     
     回答済み

    Hi JuneT,

    I tried the solution from your link too but it didnt work.It seems the SyncframeworkToolkit Samples are not updated to work in IIS.

    I used another solution and it is working:

    created a new WCF project and included  DefaultScopeSyncService and related files(except Web.config) to  this project.

    SyncframeworkToolkit by default create all the endpoints.no need to create additional endpoints in web.config.

    Host this application in IIS and the service will be available.



    • 回答としてマーク b_abrams 2012年3月30日 8:45
    •