Reformatted.
Preliminary support for users and authentication. Shared db connection.