1

IISでホストされているWCFサービスアプリケーションを使用する単純なアプリケーションを作成しています。すべてがVS12で機能しているので、IISサーバーにWCFを配置します。すべてのsvc、svc.cs、およびweb.configファイルをWCFHostフォルダーにコピーし、WCFHost /bin/にデバッガーで作成されたファイルを配置しました。IISを構成しましたが、Chromeでホストを実行しようとすると、エラーが発生します。

Server Error in '/WCFHost' Application.

Access is denied.

Description: An error occurred while accessing the resources required to serve this request. You might not have permission to view the requested resources. 

Error message 401.3: You do not have permission to view this directory or page using the credentials you supplied (access denied due to Access Control Lists). Ask the Web server's administrator to give you access to 'C:\Users\MiSiek\Documents\WcfNewsletter_2'.

Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.17929

IISで新しいアプリケーションを作成するとき、私は自分のユーザーとパスを使用しました。

私のweb.config:

    <?xml version="1.0"?>
<configuration>
  <connectionStrings>
    <add name="NewsletterEntities" connectionString="metadata=res://*/NewsletterDAL_EF.csdl|res://*/NewsletterDAL_EF.ssdl|res://*/NewsletterDAL_EF.msl;provider=System.Data.SqlClient;provider connection string=&quot;Data Source=(local)\SQLEXPRESS;Initial Catalog=Newsletter;Integrated Security=True;Pooling=False;MultipleActiveResultSets=True&quot;" providerName="System.Data.EntityClient"/>
  </connectionStrings>
  <appSettings>
    <add key="aspnet:UseTaskFriendlySynchronizationContext" value="true" />
  </appSettings>

  <system.web>
    <compilation debug="true" targetFramework="4.5" />
    <httpRuntime targetFramework="4.5"/>
  </system.web>
  <system.serviceModel>
    <services>
      <service name="WCFHost.MessageService">
        <endpoint address="" binding="basicHttpBinding" contract="WCFHost.IMessageService">
          <identity>
            <dns value="localhost" />
          </identity>
        </endpoint>
        <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" />
        <host>
          <baseAddresses>
            <add baseAddress="http://localhost:8733/WcfServiceLibrary/MessageService/" />
          </baseAddresses>
        </host>
      </service>
      <service name="WCFHost.MailingListService">
        <endpoint address="" binding="basicHttpBinding" contract="WCFHost.IMailingListService">
          <identity>
            <dns value="localhost" />
          </identity>
        </endpoint>
        <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" />
        <host>
          <baseAddresses>
            <add baseAddress="http://localhost:8733/WcfServiceLibrary/MailingListService/" />
          </baseAddresses>
        </host>
      </service>
      <service name="WCFHost.RecipientService">
        <endpoint address="" binding="basicHttpBinding" contract="WCFHost.IRecipientService">
          <identity>
            <dns value="localhost" />
          </identity>
        </endpoint>
        <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" />
        <host>
          <baseAddresses>
            <add baseAddress="http://localhost:8733/WcfServiceLibrary/RecipientService/" />
          </baseAddresses>
        </host>
      </service>
      <service name="WCFHost.SenderService">
        <endpoint address="" binding="basicHttpBinding" contract="WCFHost.ISenderService">
          <identity>
            <dns value="localhost" />
          </identity>
        </endpoint>
        <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" />
        <host>
          <baseAddresses>
            <add baseAddress="http://localhost:8733/WcfServiceLibrary/SenderService/" />
          </baseAddresses>
        </host>
      </service>
    </services>
    <behaviors>
      <serviceBehaviors>
        <behavior>
          <!-- To avoid disclosing metadata information, set the values below to false before deployment -->
          <serviceMetadata httpGetEnabled="true" httpsGetEnabled="true"/>
          <!-- To receive exception details in faults for debugging purposes, set the value below to true.  Set to false before deployment to avoid disclosing exception information -->
          <serviceDebug includeExceptionDetailInFaults="false"/>
        </behavior>
      </serviceBehaviors>
    </behaviors>

    <protocolMapping>
      <add binding="basicHttpsBinding" scheme="https" />
    </protocolMapping>

    <serviceHostingEnvironment aspNetCompatibilityEnabled="true" multipleSiteBindingsEnabled="true" />
  </system.serviceModel>
  <system.webServer>
    <modules runAllManagedModulesForAllRequests="true"/>
    <!--
        To browse web app root directory during debugging, set the value below to true.
        Set to false before deployment to avoid disclosing web app folder information.
      -->
    <directoryBrowse enabled="true"/>
  </system.webServer>

</configuration>
4

0 に答える 0