Syncing Custom Attributes for Users and Groups

Custom attributes for Users and Groups have been presented in Metric Insights 6.3.4 and allow syncing custom attributes from Okta, LDAP, and Microsoft 365 using mi-okta-usersync, mi-ldap-usersync, and mi-o365-usersync respectively. Each custom attribute that needs to be synced must be created in MI. All synced custom attributes are displayed on the Info tab of User/Group Editor.

The process comprises the following steps:

 Find Values for Custom Attributes

  1. Create a Custom Attribute
  2. Configure Custom Attribute
  3. Run Usersync Script
  4. View Sync Results
    1. View Synced Groups
    2. View Synced Users

NOTE: Custom group attributes cannot be synced by mi-o365-usersync script from Microsoft 365 since it is not supported by AD B2C on Azure.

Find Values for Custom Attributes

1. Create a Custom Attribute

  1. Access Custom Attributes:
    • v6: Go to <MI hostname>/admin/customattribute
    • v7: Go to <MI hostname>/admin/custom-attribute
  2. [+ Custom Attribute]

2. Configure Custom Attribute

Access the Settings tab

NOTE: Each Custom Attribute that needs to be synced from Okta/LDAP/Microsoft 365 must be created in Metric Insights.

  1. Enter a Custom Attribute Name that will be displayed in User or Group Editor
  2. External ID: Enter the corresponding attribute name from Okta/LDAP/Microsoft 365
  3. Optionally, provide a Description that will be displayed on hover in User/Group Editor
  4. Choose whether the attribute is displayed for Users, Groups, or both

NOTE: Custom group attributes cannot be synced from Microsoft 365 since it is not supported by AD B2C on Azure.

  1. [Save]

3. Run Usersync Script

mi-ldap-usersync, mi-okta-usersync

NOTES:

  • If more than one custom user or group attribute is synced, separate the attribute names with commas omitting whitespaces.
  • See Find Values for Custom Attributes for details on where to find custom attributes' values in Okta or LDAP directory services.
  1. Enter the External IDs of the custom user attributes that need to be synced using the --custom-user-attribute parameter
  2. Enter the External IDs of the custom group attributes that need to be synced using the --custom-group-attribute parameter
  3. Use --map-attr-to-group to select an attribute which will map users to groups based on this attribute's value
    • If the group(s) do not exist in Metric Insights, use --auto-create all to auto-create them in MI
  4. Sync summary is displayed listing all added users and groups

mi-o365-usersync

NOTE:

  1. Enter custom user attributes that need to be synced using the --custom-user-attribute parameter
  2. Enter the application ID used by Azure AD to store user data using the --custom-attr-app-id
    • It can be found by accessing Azure AD B2C > App registrations > All applications

Optionally, use --map-attr-to-group to select an attribute which will map users to groups based on this attribute's value

  • If the group(s) do not exist in Metric Insights, use --auto-create all to auto-create them in MI

4. View Sync Results

4.1. View Synced Groups

Access Admin > Users & Groups > Groups tab

  1. Click on the added group
  2. Access the Info tab, the synced Custom Group Attributes are displayed at the bottom of the page
  3. Access the Members tab, the synced users are displayed on the Members tab
  4. Click on one of the synced Users

4.2. View Synced Users

Access the Info tab

  1. The synced Custom User Attributes are displayed at the bottom of the page
  2. Access the Group Membership tab
  3. The synced User has been added to a group defined in the --map-attr-to-group parameter