Shiro簡介
Apache Shiro是一個強大且易用的Java安全框架,執行身份驗證、授權、密碼學和會話管理。
Apache Shiro 體系結構:
1、Authentication 認證 ---- 用戶登錄
2、Authorization 授權 — 用戶具有哪些權限
3、Cryptography 安全數據加密
4、Session Management 會話管理
5、Web Integration web系統集成
6、Interations 集成其它應用,spring、緩存框架
分析Shiro的核心API
Subject: 用戶主體(把操作交給SecurityManager)
SecurityManager:安全管理器(關聯Realm)
Realm:Shiro連接數據的橋樑