From 3bbbf0723556bebb758b4901b93e5fbcbdea7924 Mon Sep 17 00:00:00 2001 From: Luke Taylor Date: Sun, 25 Apr 2010 20:12:00 +0100 Subject: [PATCH] SEC-1464: Fix broken test (flags in returned user object were not being copied from stored user). --- .../security/provisioning/InMemoryUserDetailsManager.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/src/main/java/org/springframework/security/provisioning/InMemoryUserDetailsManager.java b/core/src/main/java/org/springframework/security/provisioning/InMemoryUserDetailsManager.java index adf2a69017..e93df7ee09 100644 --- a/core/src/main/java/org/springframework/security/provisioning/InMemoryUserDetailsManager.java +++ b/core/src/main/java/org/springframework/security/provisioning/InMemoryUserDetailsManager.java @@ -113,8 +113,8 @@ public class InMemoryUserDetailsManager implements UserDetailsManager { throw new UsernameNotFoundException(username); } - return new User(user.getUsername(), user.getPassword(), user.isEnabled(), true, true, true, - user.getAuthorities()); + return new User(user.getUsername(), user.getPassword(), user.isEnabled(), user.isAccountNonExpired(), + user.isCredentialsNonExpired(), user.isAccountNonLocked(), user.getAuthorities()); } }