Added session authentication

First pull request!