# Two-factor authentication

### Introduction

One of the pillars of Power Embedded since its first version has always been the security of access to data and reports.

To ensure the best possible security and governance in terms of user authentication, the system offers integrated authentication with Microsoft and Google using the OAuth2 protocol, so users do not need to create another password — the same password from the identity provider is used. When a user is blocked or removed in Entra ID or Google Workspace, access is automatically blocked in Power Embedded as well.

To allow external users, such as customers and suppliers, to access reports, Power Embedded also supports internal authentication using an email address and password, where users simply provide these credentials to access the reports.

To enhance the security of users who use email and password to log in to the portal, **two-factor authentication has been implemented** in the viewer portal.

Once enabled for the user in question, when logging in with email and password, an email will be sent with a confirmation code that must be entered to complete the login process.

This measure ensures an extra layer of security to protect user information.

### How to Enable Two-Factor Authentication (MFA)

To enable this option, go to the Administration Portal > Users or [click here](https://admin.powerembedded.com.br/Users).

Click the Actions button > Edit.

Now enable the option ***Two-factor authentication when logging in using email and password***.

<figure><img src="/files/9IxnHq6k7RUdXJfXQc3G" alt=""><figcaption></figcaption></figure>

### Practical Example

Once two-factor authentication is enabled, whenever the user logs in to the reports portal using email and password, a verification code will be sent to their email address.

<figure><img src="/files/4mVXYlJ7xSUKa9sAB67s" alt=""><figcaption></figcaption></figure>

After receiving the email with the access code, the user must enter the code on this screen and click the ***Validate code*** button to continue the login process.

<figure><img src="/files/fbsdDFlaZLifExmKFhzz" alt=""><figcaption></figcaption></figure>

{% hint style="warning" %}
If the user authenticates using Microsoft or Google, this setting will have no effect, as access is validated by the identity provider and MFA settings are managed by your company's security/IT team.

Therefore, if your company enforces the use of MFA, you will need to confirm the code using the MFA method configured to authenticate in Power Embedded.
{% endhint %}


---

# Agent Instructions: 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.powerembedded.com/administration-portal/users/two-factor-authentication.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.
