Repository: incubator-ranger
Updated Branches:
  refs/heads/master 39439cebf -> ea5bf67e7


RANGER-968 Removing validation of email addresses from UserMgr

Signed-off-by: rmani <[email protected]>


Project: http://git-wip-us.apache.org/repos/asf/incubator-ranger/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ranger/commit/ea5bf67e
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ranger/tree/ea5bf67e
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ranger/diff/ea5bf67e

Branch: refs/heads/master
Commit: ea5bf67e72f12ae170e3ba93fc279016077013c1
Parents: 39439ce
Author: Bryan Bende <[email protected]>
Authored: Wed May 4 16:37:49 2016 -0400
Committer: rmani <[email protected]>
Committed: Wed May 4 15:13:07 2016 -0700

----------------------------------------------------------------------
 .../src/main/java/org/apache/ranger/biz/UserMgr.java     | 11 -----------
 1 file changed, 11 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ranger/blob/ea5bf67e/security-admin/src/main/java/org/apache/ranger/biz/UserMgr.java
----------------------------------------------------------------------
diff --git a/security-admin/src/main/java/org/apache/ranger/biz/UserMgr.java 
b/security-admin/src/main/java/org/apache/ranger/biz/UserMgr.java
index d96aa05..bd7608d 100644
--- a/security-admin/src/main/java/org/apache/ranger/biz/UserMgr.java
+++ b/security-admin/src/main/java/org/apache/ranger/biz/UserMgr.java
@@ -1118,13 +1118,6 @@ public class UserMgr {
 
        public VXPortalUser createUser(VXPortalUser userProfile) {
                checkAdminAccess();
-               String emailAddress = userProfile.getEmailAddress();
-               if (!stringUtil.isEmpty(emailAddress)) {
-                       if(!stringUtil.validateEmail(emailAddress)){
-                               logger.info("Invalid email address:" + 
emailAddress);
-                               throw restErrorUtil.createRESTException("Please 
provide valid email address.",MessageEnums.INVALID_INPUT_DATA);
-                       }
-               }
                XXPortalUser xXPortalUser = this.createUser(userProfile,
                                RangerCommonEnums.STATUS_ENABLED);
                return mapXXPortalUserVXPortalUser(xXPortalUser);
@@ -1146,10 +1139,6 @@ public class UserMgr {
                        xXPortalUser = this.findByLoginId(loginId);
                        if (xXPortalUser == null) {
                                if (!stringUtil.isEmpty(emailAddress)) {
-                                       
if(!stringUtil.validateEmail(emailAddress)){
-                                               logger.info("Invalid email 
address:" + emailAddress);
-                                               throw 
restErrorUtil.createRESTException("Please provide valid email 
address.",MessageEnums.INVALID_INPUT_DATA);
-                                       }
                                        xXPortalUser = 
this.findByEmailAddress(emailAddress);
                                        if (xXPortalUser == null) {
                                                xXPortalUser = 
this.createUser(userProfile,

Reply via email to