mercredi 16 décembre 2015

Ember-simple-auth with oauth2 fails in reload

Hei,

Hei guys. I'm trying to use ember-simple-auth with oauth2, and i'm sending the request for my /token endpoint like should be, and 'm sending back the token if the user exists in the database.. and the app is being redirect to index, but when i reload the page, i'm back in the login page. What could be causing this? I'm following the documentation.

Now i am seeing in console:

The authenticator "authenticator:oauth2" rejected to restore the session - invalidating…

That's my configs:

  ENV['ember-simple-auth'] = {
    authenticationRoute: 'login',
    routeAfterAuthentication: 'index',
    routeIfAlreadyAuthenticated: 'index',
    crossOriginWhitelist: ['http://localhost:3000']
  };

I don't know exactly what i'm doing wrong here since i just follow the docs.

Thanks.




Aucun commentaire:

Enregistrer un commentaire