Token based authentication with nodejs and angularjs