Updated server to use new SQL database and fixed a few authentication bugs.