Project

General

Profile

Revision 943dcf96

ID943dcf964c713e0a4de7c92dfca0ec4f3997bc65
Parent 51cc6f53
Child 086d2a44

Added by Andreas Kohlbecker about 2 years ago

ref #7833 adding missing check for anonymous authentication tokens to CdmUserHelper

View differences:

cdmlib-services/src/main/java/eu/etaxonomy/cdm/api/utility/CdmUserHelper.java
96 96
    @Override
97 97
    public boolean userIsAutheticated() {
98 98
        Authentication authentication = getAuthentication();
99
        if(authentication != null){
99
        if(authentication != null && !AnonymousAuthenticationToken.class.equals(authentication.getClass())){
100 100
            return authentication.isAuthenticated();
101 101
        }
102 102
        return false;
......
410 410
    }
411 411

  
412 412
    // @Override
413
    @Override
413 414
    public <T extends CdmBase> Collection<CdmAuthority> findUserPermissions(Class<T> cdmType, EnumSet<CRUD> crud) {
414 415
        Set<CdmAuthority> matches = new HashSet<>();
415 416
        CdmPermissionClass permissionClass = CdmPermissionClass.getValueOf(cdmType);

Also available in: Unified diff

Add picture from clipboard (Maximum size: 40 MB)