private boolean hasPermissionToSeeToken() {
        // Administrators can do whatever they want
        if (SHOW_LEGACY_TOKEN_TO_ADMINS && Jenkins.get().hasPermission(Jenkins.ADMINISTER)) {
            return true;
        }
        
        User current = User.current();
        if (current == null) { // Anonymous
            return false;
        }
        
        // SYSTEM user is always eligible to see tokens
        if (Jenkins.getAuthentication() == ACL.SYSTEM) {
            return true;
        }
        
        return User.idStrategy().equals(user.getId(), current.getId());
    }
private boolean hasPermissionToSeeToken ( ) { if ( SHOW_LEGACY_TOKEN_TO_ADMINS && Jenkins . get ( ) . hasPermission ( Jenkins . ADMINISTER ) ) { return true ; } User current = User . current ( ) ; if ( current == null ) { return false ; } if ( Jenkins . getAuthentication ( ) == ACL . SYSTEM ) { return true ; } return User . idStrategy ( ) . equals ( user . getId ( ) , current . getId ( ) ) ; }
Only for legacy token