Click anywhere to close this dialog

Farewell

Great is the art of beginning, but greater is the art of ending
Henry Wadsworth Longfellow

I announce that I cease all development and activity in the programming universe indefinitely. My career has reached the turning point I was not expecting for at least another year, leaving me highly off guard and without laid-out plans for this hobby's continuity. I have begun a 5-year residency program in Neurosurgery which is clearly not compatible, time-wise, with programming.

I gave in all my passion for developing, and you gave me back your loyalty and trust, even when I did not deserve that much. Now it is the time for payback. I release all my present and past work as Open Source software, in the hope some talented developer will continue maintaining and expanding my vision of a modern, sleek forum software. The intrinsic flexibility of MyBB is the true hidden gem of an otherwise outdated codebase; I do hope the project can continue and be updated complying to the latest coding standards.

I hereby thank Euan, kawaii, andrewjs18, Ben, Matt, Omar G., effone, Eric J., Devilshakerz, Wildcard, JordanMussi and all the other team members I have had the opportunity to work with when I was a MyBB team member. I thank Tomm M, my mentor, who inspired me to pick up coding with his piece-of-art plugins. And finally, I thank all of you MyBBoost subscribers who have helped me getting through my toughest university years economically.

Yours sincerely, Filippo

Error 191 "can't load URL" using facebook login app

25 Aug 2017
#1
This issue is marked as solved
I am trying to establish logging in on my myBB forum by facebook. But it constantly gives an error

"Can't Load URL: The domain of this URL isn't included in the app's domains. To be able to load this URL, add all domains and subdomains of your app to the App Domains field in your app settings."

I am sure that I've listed my domain in "App Domains" list (see screenshot). Could you please help me to investigate what exactly is wrong?

You can try it here https://forum.avangard.org.ua/ . It gives error in ukrainian language because I am from Ukraine but it's easy to find translation.

I am sure that I configured app secret and id correctly.

Sreenshots of facebook app config:
[Image: fU6Scev.png][Image: vrCxRTo.png][Image: FZBvyNU.png][Image: IUWusux.png][Image: vzJWSPJ.png]

Will be grateful for any help.

regards,
Ivan
Shade 25 Aug 2017
#2
Hello, thank you for using my plugins. In Valid OAuth redirect URIs, just add the forum domain. The issue is most likely linked to that. If I'm not mistaken, you could as well leave it empty.
Ivan Vysotskyi 27 Aug 2017
#3
Hello, Facebook doesn't allow me to leave it empty.
I've just tried it with https://forum.avangard.org.ua/myfbconnec...n=do_login - it doesn't work

With https://forum.avangard.org.ua/myfbconnec...n=do_login and https://forum.avangard.org.ua/ it doesn't work

With https://forum.avangard.org.ua/ it doesn't work.

If I type there something wrong like https://forum.avangard.org.ua/blablabla, another error appear, on facebook site it shows a message "URL is blocked"
Shade 27 Aug 2017
#4
Try to enter the domain, without the forum subdomain.
Ivan Vysotskyi 27 Aug 2017 Edited
#5
[Image: ViSXxsU.png]

If I type something instead of "https://forum.avangard.org.ua/myfbconnect.php?action=do_login" it shows an error (screenshot).

Why do you think it could work for "avangard.org.ua"? It's a completely different site. If I had site smth.us.com should I print just "us.com" in the redirect url field?

I understand now that my issue is not typical and I should insert trace statements into php code and debug it mysef.

thank you for replies.
Shade 27 Aug 2017 Edited
#6
This is certainly not a fault of the code, but a fault of the app configuration. You won't go far by adding stack traces randomly, the error is on Facebook's side.

"forum" should be the subdomain, adding the primary domain should whitelist all the subdomains.

Try to add the site WITHOUT the https prefix (like: forum.avangard.org.ua).
Ivan Vysotskyi 28 Aug 2017 Edited
#7
I did it and when press "Save changes" , facebook replaced it with http(not https) and gives the same error 191. I also tried to add both http://forum.... and https://forum.... to redirect url and it doesn't work.[Image: Hw1wESK.png]
Content of xml bugreport:
<?xml version="1.0" encoding="UTF-8"?>
<report name="MyFacebook Connect" version="3.2">
<id>32</id>
<dateline>1503730447</dateline>
<code>191</code>
<file>/home/avangard.org.ua/forum/myfbconnect/src/Facebook/Exceptions/FacebookResponseException.php</file>
<line>131</line>
<message>{translated from Ukrainian}Can't Load URL: The domain of this URL isn't included in the app's domains. To be able to load this URL, add all domains and subdomains of your app to the App Domains field in your app settings.</message>
<trace> /home/relliart/avangard.org.ua/forum/myfbconnect/src/Facebook/FacebookResponse.php(210): Facebook\Exceptions\FacebookResponseExceptioncreate(Object(Facebook\FacebookResponse))
# 1 /home/relliart/avangard.org.ua/forum/myfbconnect/src/Facebook/FacebookResponse.php(255): Facebook\FacebookResponse->makeException()
# 2 /home/relliart/avangard.org.ua/forum/myfbconnect/src/Facebook/FacebookResponse.php(82): Facebook\FacebookResponse->decodeBody()
# 3 /home/relliart/avangard.org.ua/forum/myfbconnect/src/Facebook/FacebookClient.php(225): Facebook\FacebookResponse->__construct(Object(Facebook\FacebookRequest), '{"error":{"mess...', 400, Array)
# 4 /home/relliart/avangard.org.ua/forum/myfbconnect/src/Facebook/Authentication/OAuth2Client.php(277): Facebook\FacebookClient->sendRequest(Object(Facebook\FacebookRequest))
# 5 /home/relliart/avangard.org.ua/forum/myfbconnect/src/Facebook/Authentication/OAuth2Client.php(226): Facebook\Authentication\OAuth2Client->sendRequestWithClientParams('/oauth/access_t...', Array)
# 6 /home/relliart/avangard.org.ua/forum/myfbconnect/src/Facebook/Authentication/OAuth2Client.php(166): Facebook\Authentication\OAuth2Client->requestAnAccessToken(Array)
# 7 /home/relliart/avangard.org.ua/forum/myfbconnect/src/Facebook/Helpers/FacebookRedirectLoginHelper.php(228): Facebook\Authentication\OAuth2Client->getAccessTokenFromCode('AQCEixImMZjvP9o...', 'https://forum.a...')
# 8 /home/relliart/avangard.org.ua/forum/inc/plugins/MyFacebookConnect/class_facebook.php(127): Facebook\Helpers\FacebookRedirectLoginHelper->getAccessToken()
# 9 /home/relliart/avangard.org.ua/forum/myfbconnect.php(63): MyFacebook->save_token()
# 10 {main}</trace>
</report>

It would be great to get screenshots of app configuration from people who have https site and this plugin works on it. Then I could compare my settings and maybe find a mistake.

Also while installation of plugin I had a message that it was unable to connect to 443 port of localhost. But I forced installation. Can it be the issue? I contacted hosting provider and was told that 443 port is open on my site. Can I test 443 port somehow?
Shade 28 Aug 2017
#8
Maybe you've got to add both your primary domain and your subdomain (forum.). I would like to help you further but my FB account is locked at the moment and I have got no time to gain control over it.
Ivan Vysotskyi 29 Aug 2017
#9
I don't see any reasons to include primary domain. And I've already tried it. I've just reported issue on https://developers.facebook.com/bugs/
Will wait for their reply.
Ivan Vysotskyi 2 Sep 2017 Edited
#10
Facebook developer found a bug in your plugin.

Here:
https://github.com/Shade-/MyFacebook-Con...k.php#L127

I replaced line 127 with following:
$access_token = $helper->getAccessToken($this->fallback);

and it fixed problem for me. The problem is that you pass null to getAccessToken and it remains null that's why facebook said that it was not a valid url:
https://github.com/facebook/php-graph-sd...r.php#L215

If will patch your code locally on my site and will wait for plugin update.

Thank you for looking into issue.