From b8669dd32d62f2ae51204e4c419f0a6c9e446532 Mon Sep 17 00:00:00 2001 From: EliuX Date: Mon, 19 Feb 2018 13:05:45 -0500 Subject: [PATCH] Adds UserDetails to Authentication Adding the `UserDetails` object to the `Authentication` of the session allows more flexibility; e.g. custom loaded data can be use along the session by doing --- .../SpringSecurityPasswordValidationCallbackHandler.java | 1 + 1 file changed, 1 insertion(+) diff --git a/spring-ws-security/src/main/java/org/springframework/ws/soap/security/wss4j2/callback/SpringSecurityPasswordValidationCallbackHandler.java b/spring-ws-security/src/main/java/org/springframework/ws/soap/security/wss4j2/callback/SpringSecurityPasswordValidationCallbackHandler.java index fa1e5efe9..f1e3916af 100644 --- a/spring-ws-security/src/main/java/org/springframework/ws/soap/security/wss4j2/callback/SpringSecurityPasswordValidationCallbackHandler.java +++ b/spring-ws-security/src/main/java/org/springframework/ws/soap/security/wss4j2/callback/SpringSecurityPasswordValidationCallbackHandler.java @@ -94,6 +94,7 @@ protected void handleUsernameTokenPrincipal(UsernameTokenPrincipalCallback callb if (logger.isDebugEnabled()) { logger.debug("Authentication success: " + authRequest.toString()); } + authRequest.setDetails(user); SecurityContextHolder.getContext().setAuthentication(authRequest); }