This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch shiro-improvement-auth
in repository https://gitbox.apache.org/repos/asf/camel.git

commit d10b3c226af79b039240fd2c4e64f281350a9074
Author: Andrea Cosentino <[email protected]>
AuthorDate: Tue Nov 25 09:48:07 2025 +0100

    CAMEL-22722 - Camel-Shiro: Improve Authentication Error logging
    
    Signed-off-by: Andrea Cosentino <[email protected]>
---
 .../component/shiro/security/ShiroSecurityProcessor.java  | 15 ---------------
 1 file changed, 15 deletions(-)

diff --git 
a/components/camel-shiro/src/main/java/org/apache/camel/component/shiro/security/ShiroSecurityProcessor.java
 
b/components/camel-shiro/src/main/java/org/apache/camel/component/shiro/security/ShiroSecurityProcessor.java
index 05002aefc691..29b1271fa2c5 100644
--- 
a/components/camel-shiro/src/main/java/org/apache/camel/component/shiro/security/ShiroSecurityProcessor.java
+++ 
b/components/camel-shiro/src/main/java/org/apache/camel/component/shiro/security/ShiroSecurityProcessor.java
@@ -26,9 +26,6 @@ import 
org.apache.camel.support.processor.DelegateAsyncProcessor;
 import org.apache.camel.util.ObjectHelper;
 import org.apache.shiro.SecurityUtils;
 import org.apache.shiro.authc.AuthenticationException;
-import org.apache.shiro.authc.IncorrectCredentialsException;
-import org.apache.shiro.authc.LockedAccountException;
-import org.apache.shiro.authc.UnknownAccountException;
 import org.apache.shiro.authc.UsernamePasswordToken;
 import org.apache.shiro.authz.Permission;
 import org.apache.shiro.crypto.cipher.ByteSourceBroker;
@@ -148,18 +145,6 @@ public class ShiroSecurityProcessor extends 
DelegateAsyncProcessor {
             try {
                 currentUser.login(token);
                 LOG.debug("Current user {} successfully authenticated", 
currentUser.getPrincipal());
-            } catch (UnknownAccountException uae) {
-                throw new UnknownAccountException(
-                        "Authentication Failed. There is no user with username 
of " + token.getPrincipal(), uae.getCause());
-            } catch (IncorrectCredentialsException ice) {
-                throw new IncorrectCredentialsException(
-                        "Authentication Failed. Password for account " + 
token.getPrincipal() + " was incorrect!",
-                        ice.getCause());
-            } catch (LockedAccountException lae) {
-                throw new LockedAccountException(
-                        "Authentication Failed. The account for username " + 
token.getPrincipal() + " is locked."
-                                                 + " Please contact your 
administrator to unlock it.",
-                        lae.getCause());
             } catch (AuthenticationException ae) {
                 throw new AuthenticationException("Authentication Failed.", 
ae.getCause());
             }

Reply via email to