> ## Documentation Index
> Fetch the complete documentation index at: https://docs.abbyy.com/llms.txt
> Use this file to discover all available pages before exploring further.

# About the LicensingSettings.xml File

The LicensingSettings.xml file contains the ABBYY FlexiCapture SDK protection settings. This file is necessary for correct work of the [Licensing Service](https://docs.abbyy.com/flexi-capture/sdk/distribution/installinglicenseservice.md) in the network. When Licensing Service is used on a local computer, this file is required if you use a Hardware protection key.

The file is generated automatically during Developer or Runtime installation in automatic mode. The XML scheme of the settings is located in the LicensingSettings.xsd file. You can find this file in the Inc folder (Start > Programs > ABBYY FlexiCapture 12 SDK > Include Files Folder).

## Changing the Licensing Service settings

The Licensing Service settings include two main parts:

* the settings of the Licensing Service installed on the current computer, which are specified in the \<LocalLicenseServer> tag,
* and the parameters of connection with the network server, where the Licensing Service is installed. These parameters are specified in the \<LicensingServers>\&lt;MainNetworkLicenseServer> tag.

If ABBYY FlexiCapture SDK is installed on a local computer, you should specify the settings only in the \<LocalLicenseServer>, if necessary. While if ABBYY FlexiCapture SDK works in a network, \<LocalLicenseServer> parameters are specified on the server, and \<LicensingServers>\&lt;MainNetworkLicenseServer> parameters on workstations. If a computer is used both as a server and as a workstation, both \<LocalLicenseServer> and \<LicensingServers>\&lt;MainNetworkLicenseServer> parameters should be specified. See the descriptions of tags below for details.

> [accordion] To change TCP/IP port
>
> The Licensing Service uses 3024 TCP/IP port by default. If this port is closed on the computer where the Licensing Service is installed, the Licensing Service will not work. In this case, specify an open port in EndPointName attribute of \<LocalLicenseServer> or \<LicensingServers>\&lt;MainNetworkLicenseServer> tag, for example:
>
> ```xml theme={null}
> <LocalLicenseServer>
>  <ConnectionProtocol ProtocolType="TCP/IP" EndPointName="1025"/>
> </LocalLicenseServer>
> ```
>
> or
>
> ```xml theme={null}
> <LicensingServers>
>  <MainNetworkLicenseServer ServerAddress="computername" ProtocolType="TCP/IP" EndPointName="1025"/>
> </LicensingServers>
> ```

> [accordion] To disable hardware protection keys
>
> The Licensing Service enables using both hardware and software protection keys by default. If you do not use hardware protection keys, you can disable them. Set the Enable attribute of \<LocalLicenseServer>\&lt;EnableCodeMeterLicenses> tag to "no":
>
> ```xml theme={null}
> <LocalLicenseServer>
>  <ConnectionProtocol ProtocolType="<Protocol type>" />
>  <EnableCodeMeterLicenses Enable="no" />
> </LocalLicenseServer>
> ```

## License activation via a proxy server

If you need to activate a license when your machine is connected to the Internet via a proxy server, specify the connection parameters in \<ProxyServer> tag.

The protocols supported are SOCKS5 and HTTP. For HTTP, you can use basic access authentication or no authentication, for SOCKS username/password or no authentication.

Here is a sample file for activation via a proxy server:

```xml theme={null}
<LocalLicenseServer>
  <ConnectionProtocol ProtocolType="Sockets" />
</LocalLicenseServer>
<ProxyServer Type="SOCKS" Host="192.168.56.1" Port="9090" Login="user" Password="password">
```

## Using an Online License with a proxy server

An Online License does not require any special settings, but to connect via a proxy server you should specify its parameters in \<OnlineLicensing> tag.

The protocol supported is HTTP for which you can use Anonymous, Basic or Digest [authentication schemes](http://docs.microsoft.com/en-us/dotnet/framework/wcf/feature-details/understanding-http-authentication).

Here is a sample file with the proxy server settings for Online Licensing:

```xml theme={null}
<LocalLicenseServer>
  <OnlineLicensing Timeout="timeout_time" ProxyServer="http://<server_name>:<port_number>" ProxyAuth="<login>:<password>" />
  <ConnectionProtocol ProtocolType="<Protocol type>" />
</LocalLicenseServer>
```

## Setting up a redundant license server configuration

For licenses distributed via the network, you have the option of setting up a two-server configuration which will allow one of the servers to act as a backup to another in the case it goes offline.

In this case you will need [Network](https://docs.abbyy.com/flexi-capture/sdk/licensing/licensing.md#standalone-network) Runtime Licenses, which will be activated on both license servers. The workstations must specify the addresses of both servers in \<LicensingServers>\&lt;MainNetworkLicenseServer> and \<LicensingServers>\&lt;BackupNetworkLicenseServer> tags. Each of the servers must specify the address of the other in \<LocalLicenseServer>\&lt;RedundancyNetworkLicenseServer>, together with the synchronization settings. While using the license, the workstations will interact with the main license server, sending the license parameters and usage statistics to it. The main license server will regularly synchronize this data with the backup server.

If the main license server fails, the backup server takes over the license management and continues to store information coming from the workstations. When the main server goes online, the license data is synchronized with the backup, and the main server again starts managing the licenses. However, if the main server is not restored during some time, the backup server will stop functioning when this time runs out. This time may be different depending on your license.

If the backup license server fails while the main server is working, the system will continue to work as if there is only one license server. When the backup server is restored, it will be synchronized with the main server and start function as a backup again.

> [accordion] Sample of a redundant configuration
>
> For the workstation:
>
> ```xml theme={null}
> <LicensingServers>
>  <MainNetworkLicenseServer ServerAddress="mainserver" ProtocolType="TCP/IP" EndPointName="1025"/>
>  <BackupNetworkLicenseServer ServerAddress="backupserver" ProtocolType="TCP/IP" EndPointName="1025"/>
> </LicensingServers>
> ```
>
> For the main license server:
>
> ```xml theme={null}
> <LocalLicenseServer>
>  <ConnectionProtocol ProtocolType="TCP/IP" EndPointName="1025"/>
>  <RedundancyNetworkLicenseServer ServerAddress="backupserver" ProtocolType="TCP/IP" EndPointName="1025"/>
> </LocalLicenseServer>
> ```
>
> For the backup license server:
>
> ```xml theme={null}
> <LocalLicenseServer>
>  <ConnectionProtocol ProtocolType="TCP/IP" EndPointName="1025"/>
>  <Redundancy NetworkLicenseServer ServerAddress="mainserver" ProtocolType="TCP/IP" EndPointName="1025"/>
> </LocalLicenseServer>
> ```

> [!NOTE]
>
> If you need to use this configuration, please make sure that your license supports it. Contact your sales manager to find out.

## Description of Tags

<table width="100%"><thead><tr><th>**Tag**</th><th>**Type**</th><th>**Multiplicity**</th><th>**Parent Tag**</th><th>**Description**</th></tr></thead><tbody><tr><td>LicensingSettings</td><td>LicensingSettings.Elements:<ul><li>LocalLicenseServer</li><li>LicensingServers</li></ul></td><td>1</td><td>no</td><td>Protection settings.</td></tr><tr><td>LocalLicenseServer</td><td>LocalLicenseServerSettings.Elements:<ul><li>ConnectionProtocol</li><li>EnableCodeMeterLicenses</li><li>RedundancyNetworkLicenseServer</li></ul></td><td>0...1</td><td>LicensingSettings</td><td>The parameters of the Licensing Service located on the same computer.</td></tr><tr><td>ConnectionProtocol</td><td>Complex Type.Attributes:<ul><li>*ProtocolType* — the protocol type: LocalInterprocessCommunication, NamedPipes, TCP/IP, or Sockets.</li></ul>**Note:** This is an additional protocol type for the local Licensing Service. It is not necessary to specify this attribute for a standalone installation, as Standalone licenses are always used with the LocalInterprocessCommunication protocol type.<ul><li>*EndPointName* — (optional) TCP/IP port. By default, "3024".</li></ul></td><td>0...1</td><td>LocalLicenseServer</td><td>The parameters of the connection protocol.</td></tr><tr><td>OnlineLicensing</td><td>Complex Type.Attributes:<ul><li>*Timeout *— (optional) specifies reconnection period</li></ul>Currently the only supported protocol for connection via a proxy server is HTTP, for which you may specify the following attributes:<ul><li>*ProxyServer — *(optional) the address of the proxy server and the connection settings, as a string "*protocol://server:port*", where the substrings' meanings are:</li></ul><ul><li>*protocol* — the protocol used to connect to the proxy server. Currently the only supported value is HTTP.</li><li>*server* — the name or IP-address of the proxy server.</li><li>*port* — the connection port.</li></ul><ul><li>*ProxyAuth — *(optional) authentication to a proxy server as a string "*login:password*", where the substrings' meanings are:</li></ul><ul><li>*login* — the username for authorization.</li><li>*password* — the password for authorization.</li></ul></td><td>0...1</td><td>LocalLicenseServer</td><td>Specifies whether online licenses can be used on the computer.</td></tr><tr><td>EnableCodeMeterLicenses</td><td>Complex Type.Attributes:<ul><li>*Enable* — specifies whether CodeMeter protection keys can be used on the computer (set it to "yes" or "no"). By default, "yes".</li></ul></td><td>0...1</td><td>LocalLicenseServer</td><td>Specifies whether CodeMeter protection keys can be used on the computer.</td></tr><tr><td>RedundancyNetworkLicenseServer</td><td>NetworkServerAddress.Attributes:<ul><li>*ServerAddress* — the DNS name or IP address of another server in the redundant configuration.</li><li>*ProtocolType* — the protocol type: LocalInterprocessCommunication, NamedPipes, TCP/IP, or Sockets.</li><li>*EndPointName* — (optional) TCP/IP port. By default, "3024".</li></ul></td><td>0...1</td><td>LocalLicenseServer</td><td>Specifies the settings of connection to another server and synchronization with it for each of the network license servers which work together in a redundant two-server configuration.</td></tr><tr><td>LicensingServers</td><td>Complex Type.Elements:<ul><li>MainNetworkLicenseServer</li><li>BackupNetworkLicenseServer</li></ul></td><td>0...1</td><td>LicensingSettings</td><td>The list of network servers where the Licensing Service is installed.</td></tr><tr><td>MainNetworkLicenseServer</td><td>NetworkServerAddress.Attributes:<ul><li>*ServerAddress* — the DNS name or IP address of the computer where the Licensing Service is installed.</li><li>*ProtocolType* — the protocol type: LocalInterprocessCommunication, NamedPipes, TCP/IP, or Sockets.</li><li>*EndPointName* — (optional) TCP/IP port. By default, "3024".</li></ul></td><td>1</td><td>LicensingServers</td><td>The parameters of the connection with the main network server where the Licensing Service is installed.</td></tr><tr><td>BackupNetworkLicenseServer</td><td>NetworkServerAddress.Attributes:<ul><li>*ServerAddress* — the DNS name or IP address of the computer where the Licensing Service is installed.</li><li>*ProtocolType* — the protocol type: LocalInterprocessCommunication, NamedPipes, TCP/IP, or Sockets.</li><li>*EndPointName* — (optional) TCP/IP port. By default, "3024".</li></ul></td><td>0...1</td><td>LicensingServers</td><td>The parameters of the connection with the backup network license server.</td></tr><tr><td>ProxyServer</td><td>ProxyServer.Attributes:<ul><li>*Type* — the protocol to be used when connecting to the proxy server: SOCKS, HTTP.</li><li>*Host* — the name or IP address of the proxy server.</li><li>*Port* — the connection port.</li><li>*Login* — (optional) the username for authorization.</li><li>*Password* — (optional) the password for authorization.</li></ul></td><td>0...1</td><td>LicensingSettings</td><td>The settings of Internet connection via a proxy server, required for license activation.</td></tr></tbody></table>

## Samples

The sample below shows a simple LicensingSettings.xml file for a standalone installation. Local inter-process communication is used. Hardware protection keys are disabled.

```xml theme={null}
<?xml version="1.0" encoding="utf-8"?>
<LicensingSettings xmlns="http://www.abbyy.com/Protection/LicensingSettings">
 <LocalLicenseServer>
  <ConnectionProtocol ProtocolType="LocalInterprocessCommunication" />
  <EnableCodeMeterLicenses Enable="no" />
 </LocalLicenseServer>
</LicensingSettings>
```

The samples below show simple LicensingSettings.xml files for a network installation: a file for workstations and a file for a server. Licensing Service is located on the computer with the name "computername". The TCP/IP protocol is used for communication between the server and workstations.

For a workstation:

```xml theme={null}
<?xml version="1.0" encoding="utf-8"?>
<LicensingSettings xmlns="http://www.abbyy.com/Protection/LicensingSettings">
 <LicensingServers>
  <MainNetworkLicenseServer ServerAddress="computername" ProtocolType="TCP/IP" />
 </LicensingServers>
</LicensingSettings>
```

For a server:

```xml theme={null}
<?xml version="1.0" encoding="utf-8"?>
<LicensingSettings xmlns="http://www.abbyy.com/Protection/LicensingSettings">
 <LocalLicenseServer>
  <ConnectionProtocol ProtocolType="TCP/IP" />
 </LocalLicenseServer>
</LicensingSettings>
```

## See also

[Distribution of Applications Which Use the ABBYY FlexiCapture SDK Library](https://docs.abbyy.com/flexi-capture/sdk/distribution/redistribution.md)

[Installing the Licensing Service](https://docs.abbyy.com/flexi-capture/sdk/distribution/installinglicenseservice.md)
