directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From smckin...@apache.org
Subject [directory-fortress-core] branch FC-265 updated: remvoe extraneous validation of roles
Date Tue, 12 Mar 2019 02:07:29 GMT
This is an automated email from the ASF dual-hosted git repository.

smckinney pushed a commit to branch FC-265
in repository https://gitbox.apache.org/repos/asf/directory-fortress-core.git


The following commit(s) were added to refs/heads/FC-265 by this push:
     new 9f4bf06  remvoe extraneous validation of roles
9f4bf06 is described below

commit 9f4bf06f90488d464463b6358320176061fef968
Author: Shawn McKinney <smckinney@apache.org>
AuthorDate: Mon Mar 11 19:16:42 2019 -0500

    remvoe extraneous validation of roles
---
 .../apache/directory/fortress/core/impl/UserP.java | 30 ----------------------
 1 file changed, 30 deletions(-)

diff --git a/src/main/java/org/apache/directory/fortress/core/impl/UserP.java b/src/main/java/org/apache/directory/fortress/core/impl/UserP.java
index 6f4e196..ef87302 100755
--- a/src/main/java/org/apache/directory/fortress/core/impl/UserP.java
+++ b/src/main/java/org/apache/directory/fortress/core/impl/UserP.java
@@ -958,36 +958,6 @@ final class UserP
 
         // 2 Validate constraints on User object:
         ConstraintUtil.validate( entity );
-
-        // 3 Validate or copy constraints on RBAC roles:
-        if ( CollectionUtils.isNotEmpty( entity.getRoles() ) )
-        {
-            RoleP rp = new RoleP();
-            List<UserRole> roles = entity.getRoles();
-            for ( UserRole ure : roles )
-            {
-                Role inRole = new Role( ure.getName() );
-                inRole.setContextId( entity.getContextId() );
-                Role role = rp.read( inRole );
-                ConstraintUtil.validateOrCopy( role, ure );
-            }
-        }
-
-        // 4 Validate and copy constraints on Administrative roles:
-        if ( CollectionUtils.isNotEmpty( entity.getAdminRoles() ) )
-        {
-            List<UserAdminRole> uRoles = entity.getAdminRoles();
-            for ( UserAdminRole uare : uRoles )
-            {
-                AdminRole inRole = new AdminRole( uare.getName() );
-                inRole.setContextId( entity.getContextId() );
-                AdminRole outRole = admRoleP.read( inRole );
-                ConstraintUtil.validateOrCopy( outRole, uare );
-
-                // copy the ARBAC AdminRole attributes to UserAdminRole:
-                copyAdminAttrs( outRole, uare );
-            }
-        }
     }
 
     /**


Mime
View raw message