<?xml version="1.0"?>
<configuration>
  <configSections>
    <sectionGroup name="Symfonia.Common.Settings">
      <section name="FConfig" type="Symfonia.Common.Defs.FConfigSectionHandler, Symfonia.Common.Defs, Culture = neutral, PublicKeytoken = 94f0c0fc2739de1f"/>
    </sectionGroup>
  </configSections>
  <runtime>
	  <generatePublisherEvidence enabled="false"/>
    <assemblies><!--problem z raportami repx -->
      <add assembly="System.Runtime, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
    </assemblies>
    <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
      <dependentAssembly>
        <assemblyIdentity name="Microsoft.Practices.ServiceLocation" publicKeyToken="31bf3856ad364e35" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-1.3.0.0" newVersion="1.3.0.0" />
      </dependentAssembly>
<dependentAssembly>
    <assemblyIdentity name="Unity.Abstractions" publicKeyToken="489b6accfaf20ef0" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-5.11.7.0" newVersion="5.11.7.0" />
  </dependentAssembly>
  <dependentAssembly>
    <assemblyIdentity name="Unity.Container" publicKeyToken="489b6accfaf20ef0" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-5.11.11.0" newVersion="5.11.11.0" />
  </dependentAssembly>
  <dependentAssembly>
    <assemblyIdentity name="Microsoft.Web.WebView2.Core" publicKeyToken="2a8ab48044d2601e" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-1.0.2849.39" newVersion="1.0.2849.39" />
  </dependentAssembly>
  <dependentAssembly>
    <assemblyIdentity name="Microsoft.Web.WebView2.WinForms" publicKeyToken="2a8ab48044d2601e" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-1.0.2849.39" newVersion="1.0.2849.39" />
  </dependentAssembly>
  <dependentAssembly>
    <assemblyIdentity name="System.Runtime.CompilerServices.Unsafe" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-6.0.0.0" newVersion="6.0.0.0" />
  </dependentAssembly>
  <dependentAssembly>
    <assemblyIdentity name="System.Diagnostics.DiagnosticSource" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-8.0.0.0" newVersion="8.0.0.0" />
  </dependentAssembly>
  <dependentAssembly>
    <assemblyIdentity name="Microsoft.Extensions.Primitives" publicKeyToken="adb9793829ddae60" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-8.0.0.0" newVersion="8.0.0.0" />
  </dependentAssembly>
  <dependentAssembly>
    <assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-13.0.0.0" newVersion="13.0.0.0" />
  </dependentAssembly>
  <dependentAssembly>
    <assemblyIdentity name="Microsoft.Extensions.DependencyInjection.Abstractions" publicKeyToken="adb9793829ddae60" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-8.0.0.0" newVersion="8.0.0.0" />
  </dependentAssembly>
  <dependentAssembly>
    <assemblyIdentity name="Microsoft.Extensions.Configuration.Abstractions" publicKeyToken="adb9793829ddae60" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-8.0.0.0" newVersion="8.0.0.0" />
  </dependentAssembly>
  <dependentAssembly>
    <assemblyIdentity name="Microsoft.Extensions.Options" publicKeyToken="adb9793829ddae60" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-8.0.0.0" newVersion="8.0.0.0" />
  </dependentAssembly>
  <dependentAssembly>
    <assemblyIdentity name="Microsoft.Extensions.Configuration.Binder" publicKeyToken="adb9793829ddae60" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-8.0.0.0" newVersion="8.0.0.0" />
  </dependentAssembly>
  <dependentAssembly>
    <assemblyIdentity name="Microsoft.Extensions.Configuration" publicKeyToken="adb9793829ddae60" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-8.0.0.0" newVersion="8.0.0.0" />
  </dependentAssembly>
  <dependentAssembly>
    <assemblyIdentity name="Microsoft.Extensions.FileProviders.Abstractions" publicKeyToken="adb9793829ddae60" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-8.0.0.0" newVersion="8.0.0.0" />
  </dependentAssembly>
  <dependentAssembly>
    <assemblyIdentity name="Microsoft.Extensions.FileProviders.Physical" publicKeyToken="adb9793829ddae60" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-8.0.0.0" newVersion="8.0.0.0" />
  </dependentAssembly>
  <dependentAssembly>
    <assemblyIdentity name="Microsoft.Extensions.Logging" publicKeyToken="adb9793829ddae60" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-8.0.0.0" newVersion="8.0.0.0" />
  </dependentAssembly>
  <dependentAssembly>
    <assemblyIdentity name="Microsoft.Extensions.Logging.Abstractions" publicKeyToken="adb9793829ddae60" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-8.0.0.0" newVersion="8.0.0.0" />
  </dependentAssembly>
  <dependentAssembly>
    <assemblyIdentity name="System.Text.Json" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-8.0.0.5" newVersion="8.0.0.5" />
  </dependentAssembly>
    </assemblyBinding>
  </runtime>
  <system.transactions>
    <defaultSettings timeout="02:00:00"/>
    <machineSettings maxTimeout="02:00:00"/>
  </system.transactions>
  <Symfonia.Common.Settings>
    <FConfig>
      <Global>
        <entity name="ForceLocalMachineTime" type="System.Boolean" value="true" force="true"/>
      </Global>
    </FConfig>
  </Symfonia.Common.Settings>
  <appSettings>
    <add key="SymfoniaKSeF:Auth:Domain" value="identity.symfonia.pl"/>
	<add key="SymfoniaKSeF:Auth:TenantName" value="symfoniab2c" />
	<add key="SymfoniaKSeF:Auth:PolicySignUpSignIn" value="B2C_1A_SIGNUP_SIGNIN_PROD" />
	<add key="SymfoniaKSeF:Auth:ApiScope" value="https://symfoniab2c.onmicrosoft.com/15efe4cf-8706-415f-8a1c-5173e557ea60/Access " />
	<add key="SymfoniaKSeF:Auth:Agent:TokenScope" value="https://symfoniab2c.onmicrosoft.com/8ddf69b6-a0bf-4046-a3c3-fbdc9c45cc1a/GetToken" />
	<add key="SymfoniaKSeF:Auth:ClientId" value="7687c413-a5a4-4ae2-ab50-849dd85f2605" />
	<add key="SymfoniaKSeF:Domain" value="app.symfonia.pl" />
	<add key="SymfoniaKSeF:ApiDomain" value="app.symfonia.pl/graphql2" />
	<add key="SymfoniaKSeF:LogRequest" value="0" />
    <add key="EDeclaration:BaseUrl" value="https://app.symfonia.pl"/>
    <add key="EDeclaration:ClientId" value="7687c413-a5a4-4ae2-ab50-849dd85f2605"/>
    <add key="EDeclaration:AuthenticationDomain" value="identity.symfonia.pl"/>
    <add key="EDeclaration:TenantName" value="symfoniab2c"/>
    <add key="EDeclaration:ApiScope" value="https://symfoniab2c.onmicrosoft.com/1ced5d57-f01c-4cd8-8cd6-b22bfbc8c2be/Access"/>
    <add key="EDeclaration:PolicySignUpSignIn" value="B2C_1A_SIGNUP_SIGNIN_PROD"/>
    <!--
        <add key="HelpURL" value="http://help-develop.azurewebsites.net/Help"/>
        -->
    <!-- przy backup bazy danych trwających powyżej 600 sekund (domyślnie) można zmienić na wyższą wartość. Obsługiwana również wartość 0.
    <add key="SQLConnectionStatementTimeout" value="600" />
    -->
    <add key="TokenTime" value="15" />
    <add key="EmailHost" value="" />
    <add key="EmailPort" value="" />
    <add key="EmailFrom" value="" />
    <add key="EmailEnableSSL" value="false" />
    <add key="EmailUserName" value="" />
    <add key="EmailPassword" value="" />
	<add key="RebuildIndexesPerTable" value="1"/>
	<add key="DbSizeToRebuildIndexesPerTable" value="20"/>
	
	  <!--Wysyłka maila przez Outlooka zamiast przez MAPI
    <add key="UseHTMLBodyInOutlook" value="true"/>
    <add key="UseOutlookInsteadMapi" value="true"/>-->
	
    <!-- przy wysyłce do API ZUS trwającej powyżej 60000 milisekund (domyślnie) (1 minuta)
    <add key="SendTimeout" value="60000" />
    -->
    <!-- przy odbiorze z API ZUS trwającej powyżej 600000 milisekund (domyślnie) (10 minut)
    <add key="ReceiveTimeout" value="600000" />
    -->
  </appSettings>
  <system.serviceModel>
    <behaviors>
      <serviceBehaviors>
        <behavior name="PersonalFilesBehaviors">
          <serviceMetadata httpGetEnabled="true" />
          <serviceDebug includeExceptionDetailInFaults="true" />
          <serviceAuthorization serviceAuthorizationManagerType="PersonalFilesApi.BusinessLogic.Auth.RestAuthorizationManager, PersonalFilesApi.BusinessLogic, Version=20.0.101.0, Culture=neutral, PublicKeyToken=3342f0000400c525" />
        </behavior>
      </serviceBehaviors>
      <endpointBehaviors>
        <behavior name="web">
          <webHttp defaultOutgoingResponseFormat="Json" />
        </behavior>
      </endpointBehaviors>
    </behaviors>
    <bindings>
      <customBinding>
        <binding name="custom">
          <security defaultAlgorithmSuite="Default" authenticationMode="UserNameOverTransport"
              requireDerivedKeys="true" includeTimestamp="true" messageSecurityVersion="WSSecurity11WSTrustFebruary2005WSSecureConversationFebruary2005WSSecurityPolicy11BasicSecurityProfile10">
            <localClientSettings detectReplays="false" />
            <localServiceSettings detectReplays="false" />
          </security>
          <textMessageEncoding messageVersion="Soap11WSAddressing10" />
          <httpsTransport maxReceivedMessageSize="2147483647" maxBufferPoolSize="2147483647" />
        </binding>
      </customBinding>
      <webHttpBinding>
        <binding name="WebHttpBindingSetting" maxBufferSize="2147483647" maxBufferPoolSize="2147483647" maxReceivedMessageSize="2147483647" contentTypeMapper="PersonalFilesApi.BusinessLogic.Auth.SampleContentTypeMapper, PersonalFilesApi.BusinessLogic, Version=20.0.101.0, Culture=neutral, PublicKeyToken=3342f0000400c525">
          <readerQuotas maxDepth="2147483647" maxStringContentLength="2147483647" maxArrayLength="2147483647" maxBytesPerRead="2147483647" maxNameTableCharCount="2147483647" />
        </binding>
      </webHttpBinding>
    </bindings>
    <client>
      <endpoint address="https://uslugaterytws1.stat.gov.pl/terytws1.svc"
          binding="customBinding" bindingConfiguration="custom" contract="TerytAPI_ServiceReference.ITerytWs1"
          name="custom" />
    </client>
    <services>
      <service behaviorConfiguration="PersonalFilesBehaviors" name="PersonalFilesApi.PersonalFilesService">
        <endpoint behaviorConfiguration="web" binding="webHttpBinding" bindingConfiguration="WebHttpBindingSetting" contract="PersonalFilesApi.IPersonalFilesService" />
      </service>
    </services>
    <protocolMapping>
      <add binding="basicHttpsBinding" scheme="https" />
    </protocolMapping>
    <serviceHostingEnvironment aspNetCompatibilityEnabled="false" multipleSiteBindingsEnabled="true" />
  </system.serviceModel>

  <system.diagnostics>
    <trace autoflush="true" indentsize="4">
      <listeners>
        <!--<add name="xmlWriterListener"/>-->
        <!--<add name="consoleListener"/>-->
        <!--<add name="textWritterListener"/>-->
        <!--<add name="eventSchemaListener"/>-->
        <!--<add name="eventLogTraceListener"/>-->
        <!--<remove name="Default"/>-->
      </listeners>
    </trace>

    <sources>
      <source name="Symfonia ERP Kadry i Płace" switchName="traceSwitch" switchType="System.Diagnostics.SourceSwitch">
        <listeners>
          <!--<add name="xmlWriterListener"/>-->
          <!--<add name="consoleListener"/>-->
          <!--<add name="textWritterListener"/>-->
          <!--<add name="eventSchemaListener"/>-->
          <!--<add name="eventLogTraceListener"/>-->
          <!--<remove name="Default"/>-->
        </listeners>
      </source>
    </sources>

    <switches>
      <add name="traceSwitch" value="Off"/>
    </switches>

    <sharedListeners>
      <!--<add name="xmlWriterListener" type="System.Diagnostics.XmlWriterTraceListener" initializeData="C:\Logs\logs.xml" traceOutputOptions="DateTime, Timestamp, ProcessId, ThreadId, Callstack, LogicalOperationStack">
        <filter type="System.Diagnostics.EventTypeFilter" initializeData="Error"/>
      </add>-->
      <!--<add name="consoleListener" type="System.Diagnostics.ConsoleTraceListener" traceOutputOptions="ProcessId, DateTime, Timestamp">
        <filter type="System.Diagnostics.EventTypeFilter" initializeData="Error"/>
      </add>-->
      <!--<add name="textWritterListener" type="System.Diagnostics.TextWriterTraceListener" initializeData="C:\Logs\logs.txt" traceOutputOptions="DateTime, Timestamp, ProcessId, ThreadId, Callstack, LogicalOperationStack">
        <filter type="System.Diagnostics.EventTypeFilter" initializeData="Error"/>
      </add>-->
      <!--<add name="eventSchemaListener" type="System.Diagnostics.EventSchemaTraceListener,  System.Core, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" initializeData="C:\Logs\logs.svclog" traceOutputOptions="DateTime, Timestamp, ProcessId, ThreadId, Callstack, LogicalOperationStack" bufferSize="65536" maximumFileSize="20480000" logRetentionOption="LimitedCircularFiles" maximumNumberOfFiles="2">
        <filter type="System.Diagnostics.EventTypeFilter" initializeData="Error"/>
      </add>-->
      <!--<add name="eventLogTraceListener" type="System.Diagnostics.EventLogTraceListener" initializeData="TraceListenerLog" traceOutputOptions="DateTime, Timestamp, ProcessId, ThreadId, Callstack, LogicalOperationStack">
        <filter type="System.Diagnostics.EventTypeFilter" initializeData="Error"/>
      </add>-->
    </sharedListeners>
  </system.diagnostics>
  
</configuration>
