RegExLib.com - The first Regular Expression Library on the Web!

Please support RegExLib Sponsors

Sponsors

Expressions by User

   Displaying page 1 of 1 pages; Items 1 to 1
Title Test Details Pattern Title
Expression
^((CN=(['\w\d\s\-\&\.]+(\\/)*(\\,)*)+,\s*)*(OU=(['\w\d\s\-\&\.]+(\\/)*(\\,)*)+,\s*)*(DC=['\w\d\s\-\&]+[,]*\s*){1,}(DC=['\w\d\s\-\&]+\s*){1})$
Description
Matches LDAP path (AdsPath) in Active Directory. Modified version of regex which has been found in library. Accepts spaces after , character. Also \/ and \, sequences (escapes) in CN or OU name are accepted.
Matches
CN=John Smith, OU=Acc, DC=acme, DC=com | CN=John\, Smith US\/EXT, OU=Acc, DC=acme ,DC=com
Non-Matches
CN=John Smith, OU=Acc, DC=acme | CN=John\, Smith\, OU=Acc, DC=acme, DC=com
Author Rating: Not yet rated. Artur Faszczewski
   Displaying page 1 of 1 pages; Items 1 to 1

Copyright © 2001-2024, RegexAdvice.com | ASP.NET Tutorials