laravel - Sentry versus OAuth2 server -


i used oauth2 code api server githhub: https://github.com/lucadegasperi/oauth2-server-laravel

instead using standard laravel auth, want use sentry, because sentry have lot of features sending mail, ban, approve registration, ...

i created connection client (laravel guzzle plugin) on api server, cannot keep sentry session. ok, or not? how can know permission, groups or whatever of user on api server. each call api send access_token, enough oauth2. not have idea how keep sentry session, example:

i logged in moderator permission user, , send new request api getting moderator information, not know moderator or administrator or what, because not have sentry session.

maybe oauth:scope1,scope2 enough, , maybe not need sentry, not have sentry features (look on beginning of post).

i believe problem trivial, not know how resolve issue. not have idea :(

your issue understanding of oauth2 flawed. oauth2 authentication not authorization.

generally oauth2 have 3 servers:

  1. the authentication server (am am?)
  2. the authorization server (what can do?)
  3. the resource server (your api)

now servers 2 , 3 can (and are) same thing in case it's model query.

what happens user first talks authentication server , says, i user.
if authentication server believes them issued token use in requests resource server (there couple more steps in between question seems imply understand those).

when request made resource server access token resource server asks authentication server "who person?" validate token.

(at point have received linked id token authentication server rest of application know user as).

the resource server asks authorization server "what can person do" or "can person action x?"

the resource server receives grant or deny response authorization server , either serves response, or throws access denied response.

hopefully should on track difference between sentry , oauth2.


Comments

Popular posts from this blog

PHPMotion implementation - URL based videos (Hosted on separate location) -

javascript - Using Windows Media Player as video fallback for video tag -

c# - Unity IoC Lifetime per HttpRequest for UserStore -