change authentication mechanism

instead of doing all authentication in angular, angular is now only used
when a user is already authenticated