Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我们在 Play Framework 中有两个著名的身份验证和授权插件,Silhouette和Deadbolt 2。我的问题是这两个插件有什么区别?在什么情况下我们应该使用 Silhouette 或 Deadbolt 2?
Deadbolt 2 只是一个授权框架。Silhouette 是一个身份验证框架,它也支持基本的授权机制。
如果您需要身份验证(网络表单、社交、两因素、基本身份验证,...),那么您需要 Silhouette。
如果您需要授权(管理对您的操作的访问),那么您需要 Deadbolt 2 或 Silhouette。Deadbolt 2 是授权领域中功能更强大的一个。