Class SecurityUtils


  • public class SecurityUtils
    extends Object
    Utility class for Spring Security.
    • Method Detail

      • createTenantAuthority

        public static org.springframework.security.core.GrantedAuthority createTenantAuthority​(String tenantId)
      • createGroupAuthority

        public static org.springframework.security.core.GrantedAuthority createGroupAuthority​(String groupId)
      • setSecurityScopeProvider

        public static void setSecurityScopeProvider​(SecurityScopeProvider securityScopeProvider)
      • getCurrentUserId

        public static String getCurrentUserId()
        Get the login of the current user.
      • getCurrentSecurityScope

        public static SecurityScope getCurrentSecurityScope()
      • getSecurityScope

        public static SecurityScope getSecurityScope​(org.springframework.security.core.Authentication authentication)
      • getAuthenticatedSecurityScope

        public static SecurityScope getAuthenticatedSecurityScope()