> For the complete documentation index, see [llms.txt](https://docs.nalpeiron.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.nalpeiron.com/zentitle2-docs/developers/offline-activation.md).

# Offline Activation

Offline activation (license management) ensures that software **products can be activated and remain accessible and functional without an online connection**. This approach enables organizations to efficiently track, distribute, and monitor licenses, while offering users the flexibility to use the software in diverse environments, whether in remote locations with limited connectivity or secure environments with restricted internet access.

{% embed url="<https://www.youtube.com/watch?v=g7TNvc-YYU8>" %}

Zentitle2's implementation of offline activation uses various cryptographic techniques to ensure the authenticity, integrity, and encryption of the tokens exchanged between the client app and the online license server parties.

We support offline activations for software vendors who need to activate licenses in the field for customers without an active internet connection. Your application, integrated with the SDK, can handle this process across various development languages. When offline activation is needed, the application generates an activation request certificate that encodes the identity of the activated machine.

This certificate is sent to our core environment, which activates the seat for that customer in the cloud. We maintain a snapshot of the activation time and machine identity. An unlock certificate is then generated, which can be applied directly to the offline environment to enable the specific capabilities, features, and subscription period licensed to that customer.

## Prerequisites <a href="#prerequisites" id="prerequisites"></a>

To enable offline operations for the entitlement, the **offline lease period, which defines the expiration period for an offline-activated seat, has to be specified on the entitlement**.

{% hint style="warning" %}
The regular **lease period is not used in this case.**
{% endhint %}

The offline lease expiration date is calculated as the earlier date from 2 following values:

1. Seat activation time + offline lease period
2. Entitlement subscription end date (for subscription-based entitlement)

## Limitations <a href="#limitations" id="limitations"></a>

It’s **impossible to use the advanced feature API** (feature checkout, feature return) with an offline-activated product since there is no online connection to a Licensing API.

If such functionality is required in an isolated environment, the [Local License Server](/zentitle2-docs/ui-local-license-server/local-license-server-lls.md), a local replacement of the Licensing API, can be used instead.

## Implementation

Because there is no internet connection between the client application and the licensing server, the implementation of the seat activation, refresh, and deactivation flows is based on the exchange of the digital tokens, which carry the data required for executing the given operation.\
The **tokens are always encrypted and digitally signed**, to ensure the integrity and authenticity of the data coming either from the licensing server or the application running on the client machine.\
Depending on the flow, either one-way or a two-way token exchange process is required.

## Offline License Activation <a href="#offline-license-activation" id="offline-license-activation"></a>

```
[two-way token exchange process]
```

Offline license activation allows the user to activate the product using the process process defined below.

<div align="left"><figure><img src="/files/pfkZZ1567LqfJvhmMjbf" alt=""><figcaption></figcaption></figure></div>

The "**generate offline activation request token"** action can be repeated multiple times until the activation response token has been applied in the client application and the license has been activated.

{% hint style="warning" %}
This action is no longer available in the client app with an activated license until it expires or has been deactivated manually.
{% endhint %}

## Offline License Refresh <a href="#offline-license-refresh" id="offline-license-refresh"></a>

```
[one-way licensing-server -> client app token exchange process]
```

There is a possibility to extend the current lease period by refreshing the license as follows:

<div align="left"><figure><img src="/files/Mo5n0IgYbxh2kBgdxzGk" alt=""><figcaption></figcaption></figure></div>

**Offline license refresh functionality can be used in 2 scenarios:**

1. The user wants to refresh the lease before it expires.
2. The license already expired, but the seat hasn’t been reused by any other activation yet.

## Offline License Deactivation <a href="#offline-license-deactivation" id="offline-license-deactivation"></a>

```
[one-way client app -> licensing server token exchange process]
```

Once the license has been activated in the client app, the user can deactivate it at any time using the offline deactivation process.

<div align="left"><figure><img src="/files/x1Gt3m8ES3dI6v3EOp4Y" alt=""><figcaption></figcaption></figure></div>

The license in the app is deactivated immediately as the deactivation token is generated.

{% hint style="warning" %}
The deactivation token needs to be applied in the End User Portal to release the seat on the server.
{% endhint %}

**This is useful for end users who change machines, or lose a machine, or just need to remove a license from a device all in "offline" mode.**

→ [Learn more and see it in action](/zentitle2-docs/premium-features/end-user-portal-eup/end-user-offline-activation.md).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.nalpeiron.com/zentitle2-docs/developers/offline-activation.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
