Make login work

The OAuth-based login now works. Not the smoothest flow, but it will
get the job done.