log.info("{} External authentication succeeded for Subject: {}", getLogPrefix(), extContext.getSubject().getPrincipals()); } else if (extContext.getPrincipal() != null) { log.info("{} External authentication succeeded for Principal: {}", getLogPrefix(), extContext.getPrincipal()); extContext.setSubject(new Subject(false, Collections.singleton(extContext.getPrincipal()), Collections.emptySet(), Collections.emptySet())); } else if (extContext.getPrincipalName() != null) {