> For the complete documentation index, see [llms.txt](https://doc.dastra.eu/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://doc.dastra.eu/en/security/mfa.md).

# Strong authentication

Turn on strong authentication (6-digit code) for your account, or make it mandatory for the users of your organization.

Dastra uses [TOTP](https://en.wikipedia.org/wiki/Time-based_One-time_Password_algorithm) technology to manage users' [multi-factor authentication](https://en.wikipedia.org/wiki/Multi-factor_authentication). Users sign in with their usual password and a 6-digit code provided by an authenticator app, such as Microsoft Authenticator or Google Authenticator.

This page explains how to turn on strong authentication for your account, then how to make it mandatory for the users of your organization.

## Enable strong authentication on your account

1. Open the profile menu at the top right, click **User profile**, then click **Account security** in the left menu. You can also go directly to <https://app.dastra.eu/general-settings/account-security>.
2. In the **Protect your account with the two-steps authentication** card, click **Enable the two factors authentication**.

<figure><img src="https://2697025545-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LvBxs22wUMicv9uWp6C-1972196547%2Fuploads%2Fgit-blob-d16bf3fc69f0c33c1d2aa45b5c0e087459827d7f%2Fsecurity-mfa-1.png?alt=media" alt="Account security page: two-factor authentication card with the Enable the two factors authentication button"><figcaption><p>The two-factor authentication card in Account security</p></figcaption></figure>

3. On the **Setup the two-factors authentication** screen, install an authenticator app on your phone if you don't have one yet.
4. Scan the QR code with the app. If the app cannot scan it, enter the code shown under the text.

<figure><img src="https://2697025545-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LvBxs22wUMicv9uWp6C-1972196547%2Fuploads%2Fgit-blob-674a6c72ea72a7f0b610e660b8a9677ad02fac0b%2Fsecurity-mfa-2.png?alt=media" alt="Setup the two-factors authentication screen with the QR code to scan"><figcaption><p>The setup screen: the QR code to scan with your app</p></figcaption></figure>

5. Click **Continue**. Dastra then shows your recovery code: keep it in a safe place.
6. Each time you sign in, enter your password, then the **6-digit code** provided by your app.

<figure><img src="https://2697025545-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LvBxs22wUMicv9uWp6C-1972196547%2Fuploads%2Fgit-blob-233913bf827d66f704a995155c7ebd4d0ff2d11f%2Fsecurity-mfa-3.png?alt=media" alt="Example of an authenticator app showing 6-digit codes"><figcaption><p>Example of an authenticator app</p></figcaption></figure>

{% hint style="warning" %}
Keep the recovery code safe. If you lose your authenticator app, it lets you reset strong authentication: on the code entry screen, click **Unable to connect ?**. Without this code, your account stays locked: contact your organization owner so they reset the strong authentication of your account.
{% endhint %}

## Make strong authentication mandatory

Organization owners can require all internal users, meaning the users managed by the organization, to use strong authentication. This option is part of the organization security settings, which are reserved for the Enterprise plan.

1. Open the profile menu, click **Organisation Configuration**, then click **Security** in the left menu. You can also go directly to <https://app.dastra.eu/general-settings/security>.
2. In the **Force users to use strong authentication (two-factor)** card, turn on the switch: it changes to **Enabled**.

<figure><img src="https://2697025545-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LvBxs22wUMicv9uWp6C-1972196547%2Fuploads%2Fgit-blob-fd72e6d58bdc4d45c257bb9df0e182c4f667f902%2Fsecurity-mfa-4.png?alt=media" alt="Organization security settings: card to force strong authentication"><figcaption><p>The card that makes strong authentication mandatory</p></figcaption></figure>

{% hint style="info" %}
At their next sign-in, the users concerned cannot access the application until they have set up strong authentication. Warn your team and remind them how to keep the recovery code safe. A [passkey](https://doc.dastra.eu/en/security/passkey.md) sign-in with user verification already counts as two factors: it does not ask for a 6-digit code.
{% endhint %}


---

# 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 by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://doc.dastra.eu/en/security/mfa.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
