[Wikidata-bugs] [Maniphest] [Commented On] T77952: Wikidata POSTs do not work with central auth tokens

2014-12-18 Thread Jdlrobson
Jdlrobson added a comment.

I can't reproduce the code that was causing the issue. The only thing 
actionable I can suggest to make this easier for frontend developers is in the 
error message returned by this API when complaining about an invalid token 
state whether it is the token itself or the centralauth token provided with it.


TASK DETAIL
  https://phabricator.wikimedia.org/T77952

REPLY HANDLER ACTIONS
  Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign 
.

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Jdlrobson
Cc: Aklapper, Jdlrobson, hoo, Addshore, aude, daniel, JanZerebecki, 
Stype_and_Co.-WMF, Anomie, aaron, Wikidata-bugs, Legoktm



___
Wikidata-bugs mailing list
Wikidata-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs


[Wikidata-bugs] [Maniphest] [Commented On] T77952: Wikidata POSTs do not work with central auth tokens

2014-12-17 Thread Anomie
Anomie added a comment.

Works fine here when I swap the calls to action=centralauthtoken and 
action=query&meta=tokens with the corresponding calls to action=tokens.


TASK DETAIL
  https://phabricator.wikimedia.org/T77952

REPLY HANDLER ACTIONS
  Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign 
.

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Anomie
Cc: Aklapper, Jdlrobson, hoo, Addshore, aude, daniel, JanZerebecki, 
Stype_and_Co.-WMF, Anomie, aaron, Wikidata-bugs, Legoktm



___
Wikidata-bugs mailing list
Wikidata-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs


[Wikidata-bugs] [Maniphest] [Commented On] T77952: Wikidata POSTs do not work with central auth tokens

2014-12-17 Thread Jdlrobson
Jdlrobson added a comment.

Mmmm. I was using action tokens which is what the current JavaScript code uses. 
I was requesting centralauth token using it and edit token. Switching to csrf 
and using action=centralauthtoken do seem to work.

It looks like its the old api that's broken? Is that hiding a serious bug or 
could we throw a more meaningful error.I wasted a good few man hours trying to 
work this out! :)

Thanks @Anomie!


TASK DETAIL
  https://phabricator.wikimedia.org/T77952

REPLY HANDLER ACTIONS
  Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign 
.

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Jdlrobson
Cc: Aklapper, Jdlrobson, hoo, Addshore, aude, daniel, JanZerebecki, 
Stype_and_Co.-WMF, Anomie, aaron, Wikidata-bugs, Legoktm



___
Wikidata-bugs mailing list
Wikidata-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs


[Wikidata-bugs] [Maniphest] [Commented On] T77952: Wikidata POSTs do not work with central auth tokens

2014-12-17 Thread Anomie
Anomie added a comment.

Works fine when I try it, see 
https://www.wikidata.org/w/index.php?title=Q4115189&diff=181803304&oldid=181775095.

My test did the following:

- enwiki: `action=query&meta=userinfo` to verify logged in
- wikidatawiki: `action=query&meta=userinfo` to verify not logged in
- enwiki: `action=centralauthtoken` to get CATOKEN1
- wikidatawiki: `action=query&meta=tokens¢ralauthtoken=CATOKEN1` to get 
CSRFTOKEN
- enwiki: `action=centralauthtoken` to get CATOKEN2
- wikidatawiki: 
`action=wbsetdescription&id=Q4115189&language=en&value=...&summary=...&token=CSRFTOKEN¢ralauthtoken=CATOKEN2`
- wikidatawiki: `action=query&meta=userinfo` to verify still not logged in


TASK DETAIL
  https://phabricator.wikimedia.org/T77952

REPLY HANDLER ACTIONS
  Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign 
.

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Anomie
Cc: Aklapper, Jdlrobson, hoo, Addshore, aude, daniel, JanZerebecki, 
Stype_and_Co.-WMF, Anomie, aaron, Wikidata-bugs, Legoktm



___
Wikidata-bugs mailing list
Wikidata-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs


[Wikidata-bugs] [Maniphest] [Commented On] T77952: Wikidata POSTs do not work with central auth tokens

2014-12-16 Thread Jdlrobson
Jdlrobson added a comment.

@Stype_and_Co.-WMF @Anomie anything you guys know about? This is blocking a 
bunch of really awesome mobile wikidata editing features if you need any 
motivation :-) ...!


TASK DETAIL
  https://phabricator.wikimedia.org/T77952

REPLY HANDLER ACTIONS
  Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign 
.

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Jdlrobson
Cc: Aklapper, Jdlrobson, hoo, Addshore, aude, daniel, JanZerebecki, 
Stype_and_Co.-WMF, Anomie, Wikidata-bugs, Legoktm



___
Wikidata-bugs mailing list
Wikidata-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs


[Wikidata-bugs] [Maniphest] [Commented On] T77952: Wikidata POSTs do not work with central auth tokens

2014-12-08 Thread Jdlrobson
Jdlrobson added a comment.

Responds with {"servedby":"mw1203","error":{"code":"badtoken","info":"Invalid 
token","*":"See https://www.wikidata.org/w/api.php for API usage"}}

TASK DETAIL
  https://phabricator.wikimedia.org/T77952

REPLY HANDLER ACTIONS
  Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign 
.

To: Jdlrobson
Cc: Aklapper, Jdlrobson, jkroll, Smalyshev, Wikidata-bugs, aude, GWicke, 
Manybubbles, daniel, Legoktm



___
Wikidata-bugs mailing list
Wikidata-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs