# springboot-shiro
**Repository Path**: hale459/SpringBoot-Shiro
## Basic Information
- **Project Name**: springboot-shiro
- **Description**: SpringBoot-Shiro学习笔记
- **Primary Language**: Java
- **License**: Not specified
- **Default Branch**: master
- **Homepage**: https://gitee.com/hale459
- **GVP Project**: No
## Statistics
- **Stars**: 1
- **Forks**: 0
- **Created**: 2020-06-05
- **Last Updated**: 2021-12-07
## Categories & Tags
**Categories**: Uncategorized
**Tags**: SpringBoot, Shiro
## README
# Shrio学习笔记
## SpringBoot-Shrio
**学习环境**
> IDEA 2020
>
> SpringBoot 2.3.0
>
>Shiro 1.5.3
>
>Thymeleaf - shiro 2.0.0
### 1.Shrio核心三大对象
- Subject 用户
- SecurityManager 管理用户
- Realm 连接数据
### 2.引入整合包
#### 2.1 SpringBoot整合Shiro
```xml
org.apache.shiro
shiro-spring
1.5.3
org.apache.shiro
shiro-core
1.5.3
```
#### 2.2 Thymeleaf整合Shiro
```xml
com.github.theborakompanioni
thymeleaf-extras-shiro
2.0.0
```
### 3.编写配置类
- 自定义Realm对象
作用:用于授权和认证。
验证登录权限,获取并设置登录用户的权限。
- ShiroConfig
拿到自定义的Realm对象,并将其绑定到安全管理器中,主要在安全管理器中设置拦截、设置权限、登录校验等操作。