Comments (11)
能看看你UserService 第20行左右的代码吗
from spring-boot-shiro.
from spring-boot-shiro.
这个就是空指针嘛,要么你findname
根本没有没有拿到东西,返回了null。要么你userDao
为空,没有注入进去,自己进行排查吧
from spring-boot-shiro.
我试试
from spring-boot-shiro.
大神,就是根据你的提示我去排查了一下 findname()那个方法,做 了几个测试应该是没有问题的,userDao哪里是可以拿到数据的。但是还是会出现null空指针的问题。
: Authentication failed for token submission [com.example.demo.shiro.JWTToken@635744c8]. Possible unexpected error? (Typical or expected login exceptions should extend from AuthenticationException).
java.lang.NullPointerException: null
你可以帮我看一下是哪里出了问题么。
shrio.zip
from spring-boot-shiro.
这种问题还是靠自己吧,我也没时间( • ̀ω•́ )✧
from spring-boot-shiro.
嗯呢,感觉自己对jwt哪里还有点问题。我再看看,谢谢大佬给的思路。
from spring-boot-shiro.
好吧,对不住了
from spring-boot-shiro.
@liliangbin 请问你解决了吗,我今天花了一天,跟你一样的错误。头发快没了
from spring-boot-shiro.
emmm,那个我也是不知道出在哪里问题,但是我后来就根据楼主的思路,我就自己重新写了一个过滤器,然后自己把那个jwt 和shiro结合起来。就可以了。我把我写好的那个例子发给你看看吧。
https://github.com/liliangbin/spring-boot-jwt //这个是最开始做的那个测试用写的是能够用的
https://github.com/OpenDiningHall/Open-Dining-Hall //这个是根据那个测试后,然后写的一个小样例,
我的代码水平不是很高,也还没有多少时间来好好的修修一些小毛病。先看着吧。有事你再问我
from spring-boot-shiro.
@liliangbin
我刚刚找到解决方法了。超级开心。
http://blog.csdn.net/u011961421/article/details/78803998
感谢你的回复。你可以去看看,可以解决问题。
from spring-boot-shiro.
Related Issues (20)
- 关于filter拦截配置问题的请教 HOT 5
- smithgirlfriend HOT 1
- 配置文件 HOT 1
- 请问没有vue的代码吗? HOT 2
- 这个工具类抛出异常出错 HOT 4
- 密码的判断 HOT 1
- 用户名密码验证不应该交由shiro吗? HOT 2
- 可否从token获取用户角色,或者使用缓存,减轻数据库压力。 HOT 1
- 一大堆错误,肿么办? HOT 1
- 登录时未使用Shiro的认证器 HOT 1
- JWTUtil增加refresh HOT 3
- 密码在数据库中明文存储 HOT 1
- 敏感资源如果没有携带TOKEN HOT 4
- 关于url拦截 HOT 2
- Login并未实现保持用户信息吗 HOT 1
- 没有token 时怎么办 HOT 3
- token刷新 HOT 1
- Dependency org.apache.shiro:shiro-web, leading to CVE problem HOT 1
- Token 令牌建議不要存放密碼
- Token 令牌建議不要存放密碼 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from spring-boot-shiro.