2.0依赖升级完成

This commit is contained in:
Xiong Neng
2018-09-09 22:16:56 +08:00
parent 9e9cd02507
commit 483b642ca0
29 changed files with 41 additions and 78 deletions

View File

@ -3,7 +3,7 @@
一般来讲对于RESTful API都会有认证(Authentication)和授权(Authorization)过程保证API的安全性。
采用TOKEN认证这种方式也是再HTTP头中使用Authorization: Bearer <token>使用最广泛的TOKEN是JWT通过签名过的TOKEN。
采用TOKEN认证这种方式也是再HTTP头中使用`Authorization: Bearer <token>`使用最广泛的TOKEN是JWT通过签名过的TOKEN。
基于Shiro+JWT可实现Token认证方式
@ -60,31 +60,9 @@ GET http://localhost:9095/api/v1/join?imei=imei
```
Content-Type: application/json
Authorization: 'Bearer ' + token
Authorization: "上面拿到的token值"
```
*Body参数*
``` json
{
"username": "admin",
"password": "12345678",
"appid": "111",
"imei": "imei"
}
```
返回值:
``` json
{
"success": true,
"msg": "Login success",
"data": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJhcHBpZCI6IjExMSIsImltZWkiOiJpbWVpIiwiZXhwIjoxNTM2NDg3NTM1LCJ1c2VybmFtZSI6ImFkbWluIn0.uat7rvVLwC7bcM-jRs329RWdHIFC6P-YN7YdJrdRUHE"
}
```
## 许可证
Copyright (c) 2018 Xiong Neng

View File

@ -16,7 +16,6 @@
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>2.0.4.RELEASE</version>
<relativePath/>
</parent>
<properties>