brucec5/ubudget-api — pull request #6 by brucec5 (2013-05-01 03:36:41+00:00)
Title: User creation 3: revenge of the pull request

*Ignore the older pull requests for this. They exist in an alternate history, perhaps one in which I remembered to put in my contact lenses yesterday.*

This branch does a couple of things:
* Removes `rack-ssl-enforcer` in favor of using Rails' built in methods of enforcing https.
* Adds the ability to create users and log in users.
* Adds in infrastructure to prevent a non-logged in user from accessing certain API endpoints.

To create a user, `POST` to `/users` with post parameters `username`, `password`, and `password_confirmation`.

To log in, `POST` to `/session` with post parameters `username` and `password`.

Both of these will return a session cookie that must be stored by the app and passed on to subsequent requests to the API.

I left in the `show` and `index` routes on `/users` for now for debugging, but if anyone thinks that it would be best to just remove them now and use the console for that, I'll remove them.