This commit is contained in:
fanxb 2019-05-14 17:28:14 +08:00
parent 681210cd11
commit a6dd50a923
3 changed files with 29 additions and 5 deletions

View File

@ -10,6 +10,12 @@ categories:
**说明 springboot 版本 2.0.3<br/>源码地址:[点击跳转](https://github.com/FleyX/demo-project/tree/master/springboot_spirngsecurity_demo)**
**系列**
- [springboot+security 整合1](https://www.tapme.top/blog/detail/2018-08-20-10-37)
- [springboot+security 整合2](https://www.tapme.top/blog/detail/2018-08-21-10-38)
- [springboot+security 整合3](https://www.tapme.top/blog/detail/2018-08-22-10-38)
## 一、 介绍
&emsp;&emsp;Spring Security 是一个能够为基于 Spring 的企业应用系统提供声明式的安全访问控制解决方案的安全框架。它提供了一组可以在 Spring 应用上下文中配置的 Bean充分利用了 Spring IoCDI控制反转 Inversion of Control ,DI:Dependency Injection 依赖注入)和 AOP面向切面编程功能为应用系统提供声明式的安全访问控制功能减少了为企业系统安全控制编写大量重复代码的工作。

View File

@ -2,12 +2,20 @@
id: "2018-08-21-10-38"
date: "2018/08/21 10:38"
title: "springboot+security整合2"
tags: ["java", "spring","springboot","spring-security","security"]
tags: ["java", "spring", "springboot", "spring-security", "security"]
categories:
- "java"
- "spring boot学习"
- "java"
- "spring boot学习"
---
**说明 springboot 版本 2.0.3<br/>源码地址:[点击跳转](https://github.com/FleyX/demo-project/tree/master/springboot_spirngsecurity_demo)**
**系列**
- [springboot+security 整合1](https://www.tapme.top/blog/detail/2018-08-20-10-37)
- [springboot+security 整合2](https://www.tapme.top/blog/detail/2018-08-21-10-38)
- [springboot+security 整合3](https://www.tapme.top/blog/detail/2018-08-22-10-38)
&emsp;&emsp;紧接着上一篇,上一篇中登录验证都由 security 帮助我们完成了,如果我们想要增加一个验证码登录或者其它的自定义校验就没办法了,因此这一篇讲解如何实现这个功能。
##一、 实现自定义登录校验类

View File

@ -8,6 +8,14 @@ categories:
- "spring boot学习"
---
**说明 springboot 版本 2.0.3<br/>源码地址:[点击跳转](https://github.com/FleyX/demo-project/tree/master/springboot_spirngsecurity_demo)**
**系列**
- [springboot+security 整合1](https://www.tapme.top/blog/detail/2018-08-20-10-37)
- [springboot+security 整合2](https://www.tapme.top/blog/detail/2018-08-21-10-38)
- [springboot+security 整合3](https://www.tapme.top/blog/detail/2018-08-22-10-38)
&emsp;&emsp;这篇讲解如何自定义鉴权过程,实现根据数据库查询出的 url 和 method 是否匹配当前请求的 url 和 method 来决定有没有权限。security 鉴权过程如下:
![鉴权流程](https://raw.githubusercontent.com/FleyX/files/master/blogImg/springsecurity/20190107101130.png)
@ -237,3 +245,5 @@ public class MyFilterSecurityInterceptor extends AbstractSecurityInterceptor imp
```
完成
**本篇原创发布于:**[https://www.tapme.top/blog/detail/2018-08-22-10-38](https://www.tapme.top/blog/detail/2018-08-22-10-38)