Deadbolt 2 for Play 2.5
Deadbolt 2 is an authorization library for Play 2, and features APIs for both Java- and Scala-based applications. It allows you to apply constraints to controller actions, and to customize template rendering based on the current user.
This repository contains the Scala API for Deadbolt.
You can find documentation and examples for Deadbolt at https://deadbolt-scala.readme.io/v2.5.
Get the book!
If you want to explore Deadbolt further, you might want to take a look at the book I'm currently writing on it. You can find it at https://leanpub.com/deadbolt-2.
The Java version of Deadbolt can by found at https://github.com/schaloner/deadbolt-2-java.
2.5.x Migration guide
- There is no longer a common module shared by the Scala and Java versions of Deadbolt, so there is no more usage of Java types in the API.
- Types previously found in
be.objectify.deadbolt.core.modelsare now found in
be.objectify.deadbolt.core.DeadboltAnalyzerhas been re-implemented in Scala as
- Instead of an implicit
Request, actions now receive an explicit
AuthenticatedRequestthat contains an
- The functions of
DeadboltActionsnow return a
Future[Result]in place of an