shiro学习的两个bug还没有解决

本文探讨了在使用Shiro框架进行用户认证时遇到的多realm异常问题,以及在尝试从cookie中检索记住我的凭据时发生的加密错误。文章深入分析了异常原因,包括非法十六进制字符和加密密钥配置问题,并提供了可能的解决方案。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

  1. [http-nio-8080-exec-2] WARN org.apache.shiro.authc.pam.ModularRealmAuthenticator - Realm [com.hjsjy.shiro.realm.ShiroRealm@19121616] threw an exception during a multi-realm authentication attempt:
    java.lang.IllegalArgumentException: Illegal hexadecimal charcter n at index 0
    ModularRealmAuthenticator多realm 异常
  2. [http-nio-8080-exec-4] WARN org.apache.shiro.mgt.AbstractRememberMeManager - There was a failure while trying to retrieve remembered principals. This could be due to a configuration problem or corrupted principals. This could also be due to a recently changed encryption key, if you are using a shiro.ini file, this property would be ‘securityManager.rememberMeManager.cipherKey’ see: http://shiro.apache.org/web.html#Web-RememberMeServices. The remembered identity will be forgotten and not used for this request.
    [http-nio-8080-exec-4] WARN org.apache.shiro.mgt.DefaultSecurityManager - Delegate RememberMeManager instance of type [org.apache.shiro.web.mgt.CookieRememberMeManager] threw an exception during getRememberedPrincipals().
    org.apache.shiro.crypto.CryptoException: Unable to execute ‘doFinal’ with cipher instance [javax.crypto.Cipher@6a68ccea].
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值