<iframe src="https://www.googletagmanager.com/ns.html?id=GTM-M74D8PB" height="0" width="0" style="display:none;visibility:hidden">
Loading
Skip to NavigationSkip to Main Content
Regular Expressions in Identity Provider Routing Rules Are Case-Sensitive in Okta
Single Sign-On
Okta Classic Engine
Okta Identity Engine
Overview

This article clarifies that regular expressions (RegEx) used within Identity Provider routing rules are case-sensitive.

Solution

The regular expression used in Identity Provider routing rules is case-sensitive. This design means that any character entered in uppercase or lowercase is treated as a distinct character.

For example, if a RegEx is created to match a user's email address against the string example@email.com, it will only match if the email address provided by the user exactly matches this string, including capitalization.

  • The values Example@email.com or example@EMAIL.com will not produce a match.

  • Blank spaces are also treated as distinct characters. Any discrepancy, such as an extra space or a letter in the wrong case, will cause a mismatch.

Therefore, it is important to ensure that regular expressions are configured with the correct casing to function as intended.

If there is a specific use case where the routing rule should match a user's email address with both uppercase or lowercase because the IDP does not enforce consistency in casing of user email addresses, and it would be needed to match an user with format:  EXaMpLe@eMaiL.CoM it can be achieved by simply using

(?i)domain\.com

NOTE: Please ensure that the expression used is "(?i)domain\.com", not "(?i)DOMAIN\.com" or other varieties. The regular expressions needs to be typed in lowercase.

Loading
Regular Expressions in Identity Provider Routing Rules Are Case-Sensitive in Okta