4

andikscript/SimpleUser: spring boot简单的注册登录源码

 2 years ago
source link: https://www.jdon.com/61536
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

andikscript/SimpleUser: spring boot简单的注册登录源码

使用 Spring Boot 和 Spring Security json Web 令牌进行简单的注册和登录
技术栈:
  • Spring Boot
  • Spring Security
  • Spring Data JPA
  • JWT Authentication & Authorization
  • JWT Token
  • Refresh Token
角色:
  • MODERATOR
  • ADMIN
API:
POST/api/auth/signups 注册新账户
POST/api/auth/signin login一个账户
POST/api/auth/refreshtokeng 从刷新令牌中获取新令牌
GET/api/test/allpublic 访问内容
GET/api/test/useronly 用户访问内容
GET/api/test/modonly 版主访问内容
GET/api/test/admin 只有管理员访问内容
GET/api/test/rootonly 根目录访问内容

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK