SEC-338: Serializable and serialVersionUID missing for Authentication-related objects.
This commit is contained in:
parent
7313d5def0
commit
b0056568f0
|
@ -31,6 +31,7 @@ import org.mortbay.http.UserPrincipal;
|
||||||
public class JettyAcegiUserToken extends AbstractAdapterAuthenticationToken implements UserPrincipal {
|
public class JettyAcegiUserToken extends AbstractAdapterAuthenticationToken implements UserPrincipal {
|
||||||
//~ Instance fields ================================================================================================
|
//~ Instance fields ================================================================================================
|
||||||
|
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
private String password;
|
private String password;
|
||||||
private String username;
|
private String username;
|
||||||
|
|
||||||
|
|
|
@ -15,6 +15,8 @@
|
||||||
|
|
||||||
package org.acegisecurity;
|
package org.acegisecurity;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Represents an authority granted to an {@link Authentication} object.
|
* Represents an authority granted to an {@link Authentication} object.
|
||||||
*
|
*
|
||||||
|
@ -27,7 +29,7 @@ package org.acegisecurity;
|
||||||
* @author Ben Alex
|
* @author Ben Alex
|
||||||
* @version $Id$
|
* @version $Id$
|
||||||
*/
|
*/
|
||||||
public interface GrantedAuthority {
|
public interface GrantedAuthority extends Serializable {
|
||||||
//~ Methods ========================================================================================================
|
//~ Methods ========================================================================================================
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -28,6 +28,7 @@ import java.io.Serializable;
|
||||||
public class GrantedAuthorityImpl implements GrantedAuthority, Serializable {
|
public class GrantedAuthorityImpl implements GrantedAuthority, Serializable {
|
||||||
//~ Instance fields ================================================================================================
|
//~ Instance fields ================================================================================================
|
||||||
|
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
private String role;
|
private String role;
|
||||||
|
|
||||||
//~ Constructors ===================================================================================================
|
//~ Constructors ===================================================================================================
|
||||||
|
|
|
@ -29,6 +29,7 @@ import java.security.Principal;
|
||||||
public class PrincipalAcegiUserToken extends AbstractAdapterAuthenticationToken implements Principal {
|
public class PrincipalAcegiUserToken extends AbstractAdapterAuthenticationToken implements Principal {
|
||||||
//~ Instance fields ================================================================================================
|
//~ Instance fields ================================================================================================
|
||||||
|
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
private Object principal;
|
private Object principal;
|
||||||
private String password;
|
private String password;
|
||||||
private String username;
|
private String username;
|
||||||
|
|
|
@ -28,6 +28,7 @@ import org.acegisecurity.GrantedAuthority;
|
||||||
public class TestingAuthenticationToken extends AbstractAuthenticationToken {
|
public class TestingAuthenticationToken extends AbstractAuthenticationToken {
|
||||||
//~ Instance fields ================================================================================================
|
//~ Instance fields ================================================================================================
|
||||||
|
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
private Object credentials;
|
private Object credentials;
|
||||||
private Object principal;
|
private Object principal;
|
||||||
|
|
||||||
|
|
|
@ -30,6 +30,7 @@ import org.acegisecurity.GrantedAuthority;
|
||||||
public class UsernamePasswordAuthenticationToken extends AbstractAuthenticationToken {
|
public class UsernamePasswordAuthenticationToken extends AbstractAuthenticationToken {
|
||||||
//~ Instance fields ================================================================================================
|
//~ Instance fields ================================================================================================
|
||||||
|
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
private Object credentials;
|
private Object credentials;
|
||||||
private Object principal;
|
private Object principal;
|
||||||
|
|
||||||
|
|
|
@ -31,6 +31,7 @@ import java.io.Serializable;
|
||||||
public class AnonymousAuthenticationToken extends AbstractAuthenticationToken implements Serializable {
|
public class AnonymousAuthenticationToken extends AbstractAuthenticationToken implements Serializable {
|
||||||
//~ Instance fields ================================================================================================
|
//~ Instance fields ================================================================================================
|
||||||
|
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
private Object principal;
|
private Object principal;
|
||||||
private int keyHash;
|
private int keyHash;
|
||||||
|
|
||||||
|
|
|
@ -35,6 +35,7 @@ import java.util.List;
|
||||||
public class CasAuthenticationToken extends AbstractAuthenticationToken implements Serializable {
|
public class CasAuthenticationToken extends AbstractAuthenticationToken implements Serializable {
|
||||||
//~ Instance fields ================================================================================================
|
//~ Instance fields ================================================================================================
|
||||||
|
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
private final List proxyList;
|
private final List proxyList;
|
||||||
private final Object credentials;
|
private final Object credentials;
|
||||||
private final Object principal;
|
private final Object principal;
|
||||||
|
|
|
@ -30,6 +30,7 @@ import javax.security.auth.login.LoginContext;
|
||||||
public class JaasAuthenticationToken extends UsernamePasswordAuthenticationToken {
|
public class JaasAuthenticationToken extends UsernamePasswordAuthenticationToken {
|
||||||
//~ Instance fields ================================================================================================
|
//~ Instance fields ================================================================================================
|
||||||
|
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
private transient LoginContext loginContext = null;
|
private transient LoginContext loginContext = null;
|
||||||
|
|
||||||
//~ Constructors ===================================================================================================
|
//~ Constructors ===================================================================================================
|
||||||
|
|
|
@ -32,6 +32,7 @@ import java.security.Principal;
|
||||||
public class JaasGrantedAuthority extends GrantedAuthorityImpl {
|
public class JaasGrantedAuthority extends GrantedAuthorityImpl {
|
||||||
//~ Instance fields ================================================================================================
|
//~ Instance fields ================================================================================================
|
||||||
|
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
private Principal principal;
|
private Principal principal;
|
||||||
|
|
||||||
//~ Constructors ===================================================================================================
|
//~ Constructors ===================================================================================================
|
||||||
|
|
|
@ -31,6 +31,7 @@ import org.acegisecurity.providers.AbstractAuthenticationToken;
|
||||||
public class RememberMeAuthenticationToken extends AbstractAuthenticationToken implements Serializable {
|
public class RememberMeAuthenticationToken extends AbstractAuthenticationToken implements Serializable {
|
||||||
//~ Instance fields ================================================================================================
|
//~ Instance fields ================================================================================================
|
||||||
|
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
private Object principal;
|
private Object principal;
|
||||||
private int keyHash;
|
private int keyHash;
|
||||||
|
|
||||||
|
|
|
@ -31,6 +31,7 @@ import java.security.cert.X509Certificate;
|
||||||
public class X509AuthenticationToken extends AbstractAuthenticationToken {
|
public class X509AuthenticationToken extends AbstractAuthenticationToken {
|
||||||
//~ Instance fields ================================================================================================
|
//~ Instance fields ================================================================================================
|
||||||
|
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
private Object principal;
|
private Object principal;
|
||||||
private X509Certificate credentials;
|
private X509Certificate credentials;
|
||||||
|
|
||||||
|
|
|
@ -29,6 +29,7 @@ import org.acegisecurity.providers.AbstractAuthenticationToken;
|
||||||
public class RunAsUserToken extends AbstractAuthenticationToken {
|
public class RunAsUserToken extends AbstractAuthenticationToken {
|
||||||
//~ Instance fields ================================================================================================
|
//~ Instance fields ================================================================================================
|
||||||
|
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
private Class originalAuthentication;
|
private Class originalAuthentication;
|
||||||
private Object credentials;
|
private Object credentials;
|
||||||
private Object principal;
|
private Object principal;
|
||||||
|
|
|
@ -31,6 +31,7 @@ import org.acegisecurity.GrantedAuthorityImpl;
|
||||||
public class SwitchUserGrantedAuthority extends GrantedAuthorityImpl {
|
public class SwitchUserGrantedAuthority extends GrantedAuthorityImpl {
|
||||||
//~ Instance fields ================================================================================================
|
//~ Instance fields ================================================================================================
|
||||||
|
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
private Authentication source;
|
private Authentication source;
|
||||||
|
|
||||||
//~ Constructors ===================================================================================================
|
//~ Constructors ===================================================================================================
|
||||||
|
|
|
@ -31,6 +31,7 @@ import org.springframework.util.Assert;
|
||||||
public class User implements UserDetails {
|
public class User implements UserDetails {
|
||||||
//~ Instance fields ================================================================================================
|
//~ Instance fields ================================================================================================
|
||||||
|
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
private String password;
|
private String password;
|
||||||
private String username;
|
private String username;
|
||||||
private GrantedAuthority[] authorities;
|
private GrantedAuthority[] authorities;
|
||||||
|
|
|
@ -41,6 +41,7 @@ import javax.naming.ldap.Control;
|
||||||
public class LdapUserDetailsImpl implements LdapUserDetails {
|
public class LdapUserDetailsImpl implements LdapUserDetails {
|
||||||
//~ Static fields/initializers =====================================================================================
|
//~ Static fields/initializers =====================================================================================
|
||||||
|
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
private static final GrantedAuthority[] NO_AUTHORITIES = new GrantedAuthority[0];
|
private static final GrantedAuthority[] NO_AUTHORITIES = new GrantedAuthority[0];
|
||||||
private static final Control[] NO_CONTROLS = new Control[0];
|
private static final Control[] NO_CONTROLS = new Control[0];
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue