Got authentication working on the server side