mirror of
https://github.com/spring-projects/spring-security.git
synced 2025-07-08 11:32:47 +00:00
Refactored UsernamePasswordAuthenticationToken.getDetails() to Object.
This commit is contained in:
parent
fa2920baa7
commit
ec166e086b
@ -8,6 +8,7 @@ Changes in version 0.x (2004-xx-xx)
|
|||||||
* Added FilterToBeanProxy compatibility with ContextLoaderServlet (lazy inits)
|
* Added FilterToBeanProxy compatibility with ContextLoaderServlet (lazy inits)
|
||||||
* Extracted removeUserFromCache(String) to UserCache interface
|
* Extracted removeUserFromCache(String) to UserCache interface
|
||||||
* Improved ConfigAttributeEditor so it trims preceding and trailing spaces
|
* Improved ConfigAttributeEditor so it trims preceding and trailing spaces
|
||||||
|
* Refactored UsernamePasswordAuthenticationToken.getDetails() to Object
|
||||||
* Fixed EH-CACHE-based caching implementation behaviour when cache exists
|
* Fixed EH-CACHE-based caching implementation behaviour when cache exists
|
||||||
* Fixed Ant "release" target not including project.properties
|
* Fixed Ant "release" target not including project.properties
|
||||||
* Fixed GrantedAuthorityEffectiveAclsResolver if null ACLs provided to method
|
* Fixed GrantedAuthorityEffectiveAclsResolver if null ACLs provided to method
|
||||||
|
@ -37,10 +37,10 @@ public class UsernamePasswordAuthenticationToken
|
|||||||
//~ Instance fields ========================================================
|
//~ Instance fields ========================================================
|
||||||
|
|
||||||
private Object credentials;
|
private Object credentials;
|
||||||
|
private Object details = null;
|
||||||
private Object principal;
|
private Object principal;
|
||||||
private GrantedAuthority[] authorities;
|
private GrantedAuthority[] authorities;
|
||||||
private boolean authenticated = false;
|
private boolean authenticated = false;
|
||||||
private String details = null;
|
|
||||||
|
|
||||||
//~ Constructors ===========================================================
|
//~ Constructors ===========================================================
|
||||||
|
|
||||||
@ -83,15 +83,15 @@ public class UsernamePasswordAuthenticationToken
|
|||||||
return this.credentials;
|
return this.credentials;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void setDetails(Object details) {
|
||||||
|
this.details = details;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Object getDetails() {
|
||||||
|
return details;
|
||||||
|
}
|
||||||
|
|
||||||
public Object getPrincipal() {
|
public Object getPrincipal() {
|
||||||
return this.principal;
|
return this.principal;
|
||||||
}
|
}
|
||||||
|
|
||||||
public Object getDetails() {
|
|
||||||
return details;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setDetails(String details) {
|
|
||||||
this.details = details;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
@ -349,7 +349,7 @@ public class DaoAuthenticationProvider implements AuthenticationProvider,
|
|||||||
UsernamePasswordAuthenticationToken result = new UsernamePasswordAuthenticationToken(principal,
|
UsernamePasswordAuthenticationToken result = new UsernamePasswordAuthenticationToken(principal,
|
||||||
authentication.getCredentials(), user.getAuthorities());
|
authentication.getCredentials(), user.getAuthorities());
|
||||||
result.setDetails((authentication.getDetails() != null)
|
result.setDetails((authentication.getDetails() != null)
|
||||||
? authentication.getDetails().toString() : null);
|
? authentication.getDetails() : null);
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user