Add CORS support
Fix bad login attempts screwing up sessions
Actually add CORS support
Merge branch 'cors'