Posts

Showing posts from January, 2016

Allowing empty charachters using regular expression

Image
This post will guide you to configure regular expression, to allow empty characters (spaces) for properties like user name and role name.
Validations for User Name, Role Name and Password are done using the regular expressions provided in <Product_Home>/repository/conf/user-mgt.xml file.
I will be taking EMM product as the example. By default empty characters are not allowed for role names in management console. If you enter a role with empty character (ex: Device Manager) you will get a message as in below image.

 Follow below steps to allow empty characters for role name.
1. Go to <EMM_HOME>/repository/conf/user-mgt.xml file and open the file. Then change <RolenameJavaRegEx> property and <RolenameJavaScriptRegEx> proerty as given below Property name="RolenameJavaRegEx">[a-zA-Z0-9\s._-|//]{3,30}$</Property> Property name="RolenameJavaScriptRegEx">^\w+( \w+)*$</Property> Note - <RolenameJavaScriptRegEx> is used by …