OAuth1 icon indicating copy to clipboard operation
OAuth1 copied to clipboard

Priority OAuth under Cookies authorization.

Open oolleegg55 opened this issue 9 years ago • 2 comments

I have a problem with Chrome Extension authorization. After authorization extension sends request to server to get some data. If user is authorized on a site, extension gets current user authority (by cookies). If he is not authorized on a site - extension gets correct authority ( by oauth1 ). How can I set priority? If request is with oauth parameters then not to use cookies.

ps. English is not my native, sorry.

oolleegg55 avatar Dec 22 '15 18:12 oolleegg55

I think the WP-API will do that automatically. Ie: authenticate you via cookie (if logged in via the browser) or via oauth1 if the request is signed as such (via an app).

On 22 Dec 2015, at 18:03, Oleg [email protected] wrote:

I have a problem with Chrome Extension authorization After authorization extension sends request to server to get some data If user is authorized on a site, extension gets current user authority (by cookies) If he is not authorized on a site - extension gets correct authority ( by oauth1 ) How can I set priority? If request is with oauth parameters then not to use cookies

ps English is not my native, sorry

— Reply to this email directly or view it on GitHub.

kosso avatar Dec 22 '15 19:12 kosso

@kosso It is not right in my case. Because a Chrome Extension sends XHR with cookies. Ie:

  1. User gives authority for the Chrome Extension by name "User1";
  2. Then he logins on a site by different name, for example "User2";
  3. Then he runs the extension and the extension works with the site using name "User2". I think it is not correct. User did not give authority for "User2".

oolleegg55 avatar Dec 23 '15 06:12 oolleegg55