<commit_before>Play2.0 module for Authentication and Authorization
===========================================================

This module offers Authentication and Authorization features to Play2.0 applications

Target
---------------------------------------

This module is targets the __Scala__ version of __Play2.0__.

For the Java version of Play2.0, there is an authorization module called [Deadbolt 2](https://github.com/schaloner/deadbolt-2).

This module has been tested on Play2.0final and Play2.0.1.

Motivation
---------------------------------------

### Secure

`Security` trait in Play2.0 API does not define an identifier that identifies a user.

If you use an E-mail or a user ID as an identier, 
users can not invalidate the session when the cookie leaks.

This module creates a unique SessionID using a secure random number generator.
Even if the cookie leaks, users can invalidate the session by logging in again and 
your application can set a time limit for sessions.


### Flexible

Since `Security` trait in Play2.0 API returns `Action`, 
complicated action methods are nested too deep.

This module provides an interface that return `Either[PlainResult, User]`.
so, writing complicated action methods is easy.


Installation
---------------------------------------

1. add a repository resolver into your `Build.scala` or `build.sbt` file.

        resolvers += "t2v.jp repo" at "http://www.t2v.jp/maven-repo/"

1. add a dependency declaration into your `Build.scala` or `build.sbt` file.
    1. stable release

            "jp.t2v" %% "play20.auth" % "0.2"

    1. current version

            "jp.t2v" %% "play20.auth" % "0.3-SNAPSHOT"

For example: `Build.scala`

```scala
  val appDependencies = Seq(
    "jp.t2v" %% "play20.auth" % "0.1"
  )

  val main = PlayProject(appName, appVersion, appDependencies, mainLang = SCALA).settings(<commit_msg>update README to mention stateless, remove mention of motivation for play20-auth<commit_after>Play2.0 module for stateless authentication
===========================================================

This module adds stateless authentication features to Play2.0 applications.

Target
---------------------------------------

This module targets the __Scala__ version of __Play2.0__.

This module has been tested on Play2.0.1.

Motivation
---------------------------------------

### Stateless

### Simple

Installation
---------------------------------------

TODO...

1. add a repository resolver into your `Build.scala` or `build.sbt` file.

        resolvers += "t2v.jp repo" at "http://www.t2v.jp/maven-repo/"

1. add a dependency declaration into your `Build.scala` or `build.sbt` file.
    1. stable release

            "jp.t2v" %% "play20.auth" % "0.2"

    1. current version

            "jp.t2v" %% "play20.auth" % "0.3-SNAPSHOT"

For example: `Build.scala`

```scala
  val appDependencies = Seq(
    "jp.t2v" %% "play20.auth" % "0.1"
  )

  val main = PlayProject(appName, appVersion, appDependencies, mainLang = SCALA).settings(
{'fraction_non_alphanumeric': 0.20159151193633953, 'fraction_numerical': 0.023872679045092837, 'mean_word_length': 2.6614077669902914, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 1, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1384869', 'n_tokens_mistral': 917, 'n_tokens_neox': 845, 'n_words': 312}