shiro自定义异常无效 一定要看一下自己重写AuthorizingRealm中doGetAuthenticationInfo方法时候抛出什么异常,这抛出得是AuthenticationToken; 而我在controller里面抛出得却是UnknownAccountException,这样能捕捉到想要得自定义异常才有鬼了! #记录一下sb一样得操作 一定要看一下自己重写AuthorizingRealm中doGetAuthenticationInfo方法时候抛出什么异常,这抛出得是AuthenticationToken; if (userName == null) { throw new AuthenticationToken("用户名不正确"); } else if