Jump to content

Topic on Help talk:OAuth

Expected oauth_callback_confirmed

7
KermitLiu (talkcontribs)

I receive consumer key and secret key from wiki.

I have config consumer key and secret key in phabricator.

and callback url in wiki.


but the phabricator give me a exception :

Unhandled Exception (“Exception”)

Expected ‘oauth_callback_confirmed’ to be ‘true’!


could you give some help?

Tgr (WMF) (talkcontribs)

At a wild guess, poor error handling in your client library, which receives an error and tries to verify it as if it would be a valid token (in which case indeed it should have an oauth_callback_confirmed field).

KermitLiu (talkcontribs)

mediawiki as my wiki provider, phabricator as my consumer,

i use my wiki to try, https://github.com/wikimedia/mediawiki-oauthclient-php , demo directory , as my consumer, success.

and i add print commond, then the return parameter : key,secret, oauth_callback_confirmed .

but the phabricator as the cosumer, the phabricator give me a exception.

so, the wiki is wrong, or the phabricator is wrong?


KermitLiu (talkcontribs)
Tgr (WMF) (talkcontribs)

We use the same setup for Wikimedia's Phabritcator so it can't be that wrong. Again, my best guess is that I think you are getting an error (which can be caused by a lot of things, wrong token configuration, out-of-sync clock, cache problems...) and Phabricator does not show the error because it does not recognize it is an error. willProcessTokenRequestResponse seems to do the right thing so maybe your wiki is returning a fatal error. Check your logs to see if that's the case.

@MModell (WMF) might be able to provide more insight.

KermitLiu (talkcontribs)

thank you very much , i will try

MModell (WMF) (talkcontribs)

What url do you have set for the callback?


You need to specify the callback url like this:

https://your.phabricator.url/auth/login/mediawiki:/