How to Extract Attribute Values

Complex attribute values are ones that are buried in attribute strings and need to be parsed in order to use them. This topic shows you how you can extract complex attribute values from SharePoint and map them to Jive. This profile field mapping allows Jive to become aware of values that are buried in attribute strings by pulling out the significant pieces and mapping them to their counterparts in Jive. The following advanced regex properties are available to extract the target values from a string. You need to define the regex properties so they grab the right target value.

Note: If you make a change to any of the following transformation scenarios, then you'll need to run SharePoint Identity Synchronization.

The following Simple Extraction table shows default values for the simple extraction. These settings extract a value so it can be mapped to the SharePoint External ID or Simple override profile fields.

System Property Setting (Default) Definition
sharepoint.identity.simple.formatProvider.regex.pattern (.+) Match 1 or more of anything
sharepoint.identity.simple.formatProvider.regex.group 1 Group 1 is the value to be extracted

The following Composite Extraction table provides extraction of default values and maps them to the SharePoint Username and SharePoint Domain Name profile fields.

System Property Setting (Default) Definition
sharepoint.identity.composite.formatProvider.username.regex.pattern (.+) Match 1 or more of anything
sharepoint.identity.composite.formatProvider.username.regex.group 1 Group 1 is the value to be extracted
sharepoint.identity.composite.formatProvider.domain.regex.pattern (.+) Match 1 or more of anything
sharepoint.identity.composite.formatProvider.domain.regex.group 1 Group 1 is the value to be extracted
sharepoint.identity.composite.formatProvider.domain.regex.extract.lookupMap (advanced)
{
     "lookup": {
        "key1": "value1",
        "key2": "value2"
     },
     "defaultValue": "default"
}     
Provides a JSON representation of a lookup associative array and a default value. Property string must be a valid JSON string. The following string is the default value.

The lowercase value of the raw profile field or, in this case, the extracted value based on the regex, will be looked up against the lookup map property.

  1. If a value is found in the lookup map then it will be used.
  2. If no value is found in the lookup map and the "defaultValue" property is defined that value will be used.
  3. Otherwise the raw profile field or the extracted value will be used.
Note: Lookup functionality is only available for the SharePoint Domain Name profile field. An ERROR log entry will result if Jive cannot interpret JSON as a lookup associative array and a default value.

Examples

Check out the following examples of different ways to parse out the NETBIOS Domain name from the dn (Distinguished Name) LDAP attribute and transform it using a lookup table. This effectively maps the attribute name, dn (Distinguished Name) to SharePoint Domain Name.

System Property Setting Definition
sharepoint.identity.composite.formatProvider.domain.regex.pattern (?i)((?:\s*DC\s*=\s*([0-9.a-z_-]+)\s*(,|$)){1}) parses out the 1st domain (first DC key=value pair) or the string "JIVELAND" case-insensitive. Domain Name can consist of the following chars: 0-9a-z_-.
sharepoint.identity.composite.formatProvider.domain.regex.group 2 Group 2 is the value to be extracted

The examples in this section use the following setting for sharepoint.identity.composite.formatProvider.domain.regex.extract.lookupMap, which defines the defaultValue property, but does not define "JAF".

   
                {
                "lookup": {
                "jiveland": "JIVESOFTWARE",
                "pdx": "PORTLAND"
                },
                "defaultValue": "JIVERS"
                }
             

If the exact value for the NetBIOS domain name cannot be easily made available to Jive, but the NetBIOS domain name already exists in the LDAP attribute you can use *.formatProvider.regex.pattern and *.formatProvider.regex.group and define these properties to parse out the target value. In this example, the target value is "JIVELAND", which is the value of the 1st DC key value pair.

Note: Before resorting to transformation of something like distinguished name, check to see if the LDAP attribute msDS-PrincipalName is available for each user.  If so, this has the NetBIOSDomain\username value.

Example #1

Example #2

Example #3

In the following example defines neither a lookup for "jaf" nor does it define a defaultValue, so the raw extracted values are used.

Example #4