diff --git a/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureAccountExpiredEvent.java b/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureAccountExpiredEvent.java index 8bc4bc8965..9384f72045 100644 --- a/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureAccountExpiredEvent.java +++ b/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureAccountExpiredEvent.java @@ -1,4 +1,4 @@ -/* Copyright 2004 Acegi Technology Pty Limited +/* Copyright 2004, 2005 Acegi Technology Pty Limited * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -27,7 +27,7 @@ import net.sf.acegisecurity.UserDetails; * @version $Id$ */ public class AuthenticationFailureAccountExpiredEvent - extends AuthenticationEvent { + extends AuthenticationFailureEvent { //~ Constructors =========================================================== public AuthenticationFailureAccountExpiredEvent( diff --git a/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureAccountLockedEvent.java b/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureAccountLockedEvent.java index c239a59583..7025bcf8b1 100644 --- a/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureAccountLockedEvent.java +++ b/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureAccountLockedEvent.java @@ -26,7 +26,8 @@ import net.sf.acegisecurity.UserDetails; * @author Ben Alex * @version $Id$ */ -public class AuthenticationFailureAccountLockedEvent extends AuthenticationEvent { +public class AuthenticationFailureAccountLockedEvent + extends AuthenticationFailureEvent { //~ Constructors =========================================================== public AuthenticationFailureAccountLockedEvent( diff --git a/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureCredentialsExpiredEvent.java b/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureCredentialsExpiredEvent.java index ff2fb44c29..e2def391d0 100644 --- a/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureCredentialsExpiredEvent.java +++ b/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureCredentialsExpiredEvent.java @@ -1,4 +1,4 @@ -/* Copyright 2004 Acegi Technology Pty Limited +/* Copyright 2004, 2005 Acegi Technology Pty Limited * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -27,7 +27,7 @@ import net.sf.acegisecurity.UserDetails; * @version $Id$ */ public class AuthenticationFailureCredentialsExpiredEvent - extends AuthenticationEvent { + extends AuthenticationFailureEvent { //~ Constructors =========================================================== public AuthenticationFailureCredentialsExpiredEvent( diff --git a/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureDisabledEvent.java b/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureDisabledEvent.java index 4d7c75ca96..c4d4461e46 100644 --- a/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureDisabledEvent.java +++ b/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureDisabledEvent.java @@ -1,4 +1,4 @@ -/* Copyright 2004 Acegi Technology Pty Limited +/* Copyright 2004, 2005 Acegi Technology Pty Limited * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -26,7 +26,8 @@ import net.sf.acegisecurity.UserDetails; * @author Ben Alex * @version $Id$ */ -public class AuthenticationFailureDisabledEvent extends AuthenticationEvent { +public class AuthenticationFailureDisabledEvent + extends AuthenticationFailureEvent { //~ Constructors =========================================================== public AuthenticationFailureDisabledEvent(Authentication authentication, diff --git a/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureEvent.java b/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureEvent.java new file mode 100644 index 0000000000..a9ec87a0ff --- /dev/null +++ b/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureEvent.java @@ -0,0 +1,36 @@ +/* Copyright 2004, 2005 Acegi Technology Pty Limited + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package net.sf.acegisecurity.providers.dao.event; + +import net.sf.acegisecurity.Authentication; +import net.sf.acegisecurity.UserDetails; + + +/** + * Abstract application event which indicates authentication failure for some + * reason. + * + * @author Ben Alex + * @version $Id$ + */ +public abstract class AuthenticationFailureEvent extends AuthenticationEvent { + //~ Constructors =========================================================== + + public AuthenticationFailureEvent(Authentication authentication, + UserDetails user) { + super(authentication, user); + } +} diff --git a/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailurePasswordEvent.java b/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailurePasswordEvent.java index b396c9449e..0e2f9497af 100644 --- a/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailurePasswordEvent.java +++ b/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailurePasswordEvent.java @@ -1,4 +1,4 @@ -/* Copyright 2004 Acegi Technology Pty Limited +/* Copyright 2004, 2005 Acegi Technology Pty Limited * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -26,7 +26,8 @@ import net.sf.acegisecurity.UserDetails; * @author Ben Alex * @version $Id$ */ -public class AuthenticationFailurePasswordEvent extends AuthenticationEvent { +public class AuthenticationFailurePasswordEvent + extends AuthenticationFailureEvent { //~ Constructors =========================================================== public AuthenticationFailurePasswordEvent(Authentication authentication, diff --git a/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureUsernameNotFoundEvent.java b/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureUsernameNotFoundEvent.java index 0a276f5411..46afd5823f 100644 --- a/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureUsernameNotFoundEvent.java +++ b/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureUsernameNotFoundEvent.java @@ -1,4 +1,4 @@ -/* Copyright 2004 Acegi Technology Pty Limited +/* Copyright 2004, 2005 Acegi Technology Pty Limited * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -29,7 +29,7 @@ import net.sf.acegisecurity.UserDetails; * @author Karel Miarka */ public class AuthenticationFailureUsernameNotFoundEvent - extends AuthenticationEvent { + extends AuthenticationFailureEvent { //~ Constructors =========================================================== // ~ Constructors =========================================================== diff --git a/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureUsernameOrPasswordEvent.java b/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureUsernameOrPasswordEvent.java index d0661af000..cd49ba54ce 100644 --- a/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureUsernameOrPasswordEvent.java +++ b/core/src/main/java/org/acegisecurity/providers/dao/event/AuthenticationFailureUsernameOrPasswordEvent.java @@ -1,4 +1,4 @@ -/* Copyright 2004 Acegi Technology Pty Limited +/* Copyright 2004, 2005 Acegi Technology Pty Limited * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -33,7 +33,7 @@ import net.sf.acegisecurity.UserDetails; * @author Karel Miarka */ public class AuthenticationFailureUsernameOrPasswordEvent - extends AuthenticationEvent { + extends AuthenticationFailureEvent { //~ Constructors =========================================================== public AuthenticationFailureUsernameOrPasswordEvent( diff --git a/doc/xdocs/changes.xml b/doc/xdocs/changes.xml index c0fc3ef46c..fd23d40898 100644 --- a/doc/xdocs/changes.xml +++ b/doc/xdocs/changes.xml @@ -40,6 +40,7 @@ Refactor Authentication.isAuthenticated() handling to be more performance Silently catch NotSerializableException in AbstractProcessingFilter if rootCause is not Serializable Remove getters and setters from JdbcDaoImpl so IoC container cannot modify MappingSqlQuerys + Refactor DAO authentication failure events under a consistent abstract superclass Correct location of AuthenticationSimpleHttpInvokerRequestExecutor in clientContext.xml