Added crossDomain and xhr.withCredentials to the login ajax call and allowed credentials in the res.header.

Login appears to be working now.