PhenixID

Generate Email Address

Version: 1.4

Category: Process

Extended Category: LDAP, Mail

Action Package: Standard Actions

Description

This Action generates email addresses. In most cases email addresses are generated by an email system but in some cases they have to be generated outside the email system.

Email addresses are built from session object input. This input could be given name, last name and a string containing characters. The email address is put together of a First Part, and a Second Part and eventually a third part (incremental character). The parameter ‘Email Domain’ supports SESSION() and is added to the end of the address

In some cases a given prefix/suffix or a digit etc may be added.

ParameterDescriptionExample
LDAP Data Source[Mandatory] 
The LDAP data source where to search for email addresses.
My Active Directory
LDAP Search Base DN[Mandatory] 
The LDAP base DN. The email address search starts here to determine if the generated email address is unique.
ou=users,o=company,dc=local
LDAP Search Filter for Email Address Lookup[Optional]
The search criteria to avoid email address conflicts. Use ##EMAILADDRESS## to insert the new email address value. Supports SESSION().
Default value=(&(objectclass=user)(mail=##EMAILADDRESS##))
mail=##EMAILADDRESS##
LDAP Email Prefix[Optional]
Email prefix. Used if the current email addresses is stored with a prefix in the lookup directory. The prefix is used while searching for unique addresses in the directory. The prefix is removed from the generated address after completed directory search.
smtp:
Second LDAP Data Source[Optional]
The second LDAP data source where to search for email addresses.
My Active Directory
Second LDAP Search Base DN[Optional]
The second LDAP base DN. The email address search starts here to determine if the generated email address is unique.
ou=users,o=company,dc=local
Second LDAP Search Filter for Email Address Lookup[Optional]
The second search criteria to avoid email address conflicts. Use ##EMAILADDRESS## to insert the new email address value.
Supports SESSION().
Default value=(&(objectclass=user)(mail=##EMAILADDRESS##))
mail=##EMAILADDRESS##
Second LDAP Email Prefix[Optional]
Email prefix. Used if the current email addresses is stored with a prefix in the lookup directory. The prefix is used while searching for unique addresses in the directory. The prefix is removed from the generated address after completed directory search.
smtp:
Email Domain[Mandatory] 
The Email domain.
Supports SESSION().
@domain.local
Session Attribute for Generated Email Address[Optional]
The session attribute where the result of the generated email address will be stored (output).
Default value=emailAddress
mail
Session Attribute for First Part[Optional]
Session attribute containing the first part of the address. Make sure this value does NOT contain any special characters.
Default value=givenName
preparedGivenName
Session Attribute for Second Part[Optional]
Session attribute containing second part of the address. Make sure this value does NOT contain any special characters.
Default value=sn
preparedSn
Email Address Separator[Optional]
Separator used between the first and second part of the address (john.doe). Leave blank if no separator should be used.
.
Add Incremental Character (digit/alpha)[Optional]
If the incremental character should consist of digit/s or alphabetic characters. Leave blank to keep this option disabled.
digit
Incremental Character String[Optional]
String containing, if any, the middle part of the address. If ‘Add Incremental Character’ is set to ‘alpha’ this is the string that contains the alphanumeric characters. Make sure this value does NOT contain any special characters.
The incremental character is taken from the first character in the string. If the generated address isn’t unique, the second character is used in the address and so on until the last character in the string is reached. If the address isn’t unique after all characters have been used, digit characters are used as failover.
Supports SESSION().
Default value=abcdefghijklmnopqrstuvwxyz
axz
Incremental Character Prefix[Optional]
Used if ‘Add Incremental Character’ is enabled. Enter a separator character that will be placed in front of the incremental character. Leave blank to keep this option disabled.
_
Incremental Character Position (first/second)[Optional]
Used if ‘Add Incremental Character’ is enabled. Decides if the incremental character should be placed after the First Part (firstPart_1) OR after the Second Part. Example: firstpart_1_secondpart@domain.local. Default value: first
second

Character Replacement

Before any session attributes used in this Action are passed into the session, illegal characters should be replaced. This is done with the Action String Replacer

Below an example string that can be used in the String Replacer’s Character Mapping parameter:

å|a,ä|a,ą|a,â|a,á|a,à|a,ã|a,è|e,é|e,ê|e,ë|e,ę|e,ç|c,ć|c,ł|l,ü|u,ñ|n,û|u,ú|u,ù|u,í|i,ì|i,î|i,õ|o,ò|o,ö|o,ø|o,ó|o,ô|O,æ|ae,ś|s,ß|ss,ź|z,ż|z,Å|A,Ä|A,Â|A,Á|A,À|A,Ã|A,È|E,É|E,Ê|E,Ë|E,Ç|C,ł|l,Ü|U,Ñ|N,Û|U,Ú|U,Ù|U,Í|I,Ì|I,Í|I,Õ|O,Ò|O,Ö|O,Ø|O,Ó|O,Ô|O,Æ|AE

Use Cases

Example 1: john.doe@domain.local, john.a.doe@domain.local

Desired result:

john.doe@domain.local

Desired result if address is in use:

john.a.doe@domain.local
john.x.doe@domain.local
john.z.doe@domain.local
john.1.doe@domain.local

and so on…

NOTE!
If Incremental Character String is empty and Add Incremental Character (digit/alpha) is set to alpha the result will be john.1.doe@domain.local because there is no alpha characters to use. The fail over mechanism is digit characters starting with 1 (one).

Tip! To avoid the digit character fail over, create an Add Static Attribute action and add a long string (abcdefghijklmnopqrstuvwxyz) to the value that is used in Incremental Character String. Let’s say this value is taken from a middle name (Dave), the string may look like this: daveabcdefghijklmnopqrstuvwxyz. Run the Add Static Attribute action before this action.

ParameterValue
LDAP Data SourceMy Active Directory
LDAP Search Base DNou=users,o=company,dc=local
LDAP Search Filter for Email Address Lookup[BLANK]
LDAP Email Prefix[BLANK]
Second LDAP Data Source[BLANK]
Second LDAP Search Base DN[BLANK]
Second LDAP Search Filter for Email Address Lookup[BLANK]
Second LDAP Email Prefix[BLANK]
Email Domain@domain.local
Session Attribute for Generated Email Address[BLANK]
Session Attribute for First PartgivenName
Session Attribute for Second Partsn
Email Address Separator.
Add Incremental Character (digit/alpha)alpha
Incremental Character Stringaxz (or SESSION(sessionAttribute))
Incremental Character Prefix.
Incremental Character Position (first/second)[BLANK]

Example 2: doe.john@domain.local, doe.john_1@domain.local

Desired result:

doe.john@domain.local

Desired result if address is in use:

doe.john_1@domain.local
doe.john_2@domain.local

and so on…

ParameterValue
LDAP Data SourceMy Active Directory
LDAP Search Base DNou=users,o=company,dc=local
LDAP Search Filter for Email Address Lookup[BLANK]
LDAP Email Prefix[BLANK]
Second LDAP Data Source[BLANK]
Second LDAP Search Base DN[BLANK]
Second LDAP Search Filter for Email Address Lookup[BLANK]
Second LDAP Email Prefix[BLANK]
Email Domain@domain.local
Session Attribute for Generated Email Address[BLANK]
Session Attribute for First Partsn
Session Attribute for Second PartgivenName
Email Address Separator.
Add Incremental Character (digit/alpha)digit
Incremental Character String[BLANK]
Incremental Character Prefix_
Incremental Character Position (first/second)second

DISCLAIMER
Information provided in this document is for your information only. PhenixID makes no explicit or implied claims to the validity of this information. Any trademarks referenced in this document are the property of their respective owners.

The origin of this information may be internal or external to PhenixID. PhenixID makes all reasonable efforts to verify this information.

PhenixID - support.phenixid.se