---
title: Enable User Principal Flag
description: When the property User Mapping Mode is USER_ID, this flag indicates whether to identify the user through the user DN, as follows:
component: java-agents
version: 2025.11
page_id: java-agents:properties-reference:org.forgerock.agents.userid.mapping.mode.use.dn.enabled
canonical_url: https://docs.pingidentity.com/java-agents/2025.11/properties-reference/org.forgerock.agents.userid.mapping.mode.use.dn.enabled.html
---

# Enable User Principal Flag

When the property [User Mapping Mode](org.forgerock.agents.user.mapping.mode.html) is `USER_ID`, this flag indicates whether to identify the user through the user DN, as follows:

* If `true`, the DN is taken from universalId, retrieved from the AM user session info.

* If `false`, the user is identified by the the property [User Session Name](org.forgerock.agents.userid.mapping.mode.use.session.property.name.html).

|                          |                                                                                                                                                                                                                                               |
| ------------------------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Property name            | `org.forgerock.agents.userid.mapping.mode.use.dn.enabled`                                                                                                                                                                                     |
| Aliases                  | `com.sun.identity.agents.config.user.principal`   Introduced in Java Agent 5.0   [Recognized](preface.html#how_am_manages_multiple_aliases) from AM 6`org.forgerock.agents.userid.mapping.mode.use.dn.enabled`   Introduced in Java Agent 5.6 |
| Function                 | User mapping                                                                                                                                                                                                                                  |
| Type                     | Boolean: `true` returns true; all other strings return `false`.                                                                                                                                                                               |
| Default                  | `false`                                                                                                                                                                                                                                       |
| Bootstrap property       | No                                                                                                                                                                                                                                            |
| Required property        | No                                                                                                                                                                                                                                            |
| Restart required         | No                                                                                                                                                                                                                                            |
| Local configuration file | `AgentConfig.properties`                                                                                                                                                                                                                      |
| AM console               | Tab: `Global`Title: `Enable User Principal Flag`Legacy title: `User Principal Flag`                                                                                                                                                           |
