Facebook redirect url issue OAuthException

前端 未结 8 1934
北海茫月
北海茫月 2020-12-05 14:23

My app was working well for long time, but now I am getting the error from Facebook saying:

Content: {\"error\":{\"message\":\"Error validating verification c

相关标签:
8条回答
  • 2020-12-05 15:22

    Had the same problem today, the problem turned out to be that the redirect_uri used a http:// URL Schema, and Facebook only accepts https://

    0 讨论(0)
  • 2020-12-05 15:26

    I realize this is 6 weeks late, but I figured I'll post this here since I found a fix that worked for us. Had the same issue and after trying to encode the return url (which did not work), I realized that we were building our URL like:

    $url = "http://example.com/";
    $redirect_script = "/cgi-bin/redirect.cgi";
    
    $redirect_url = $url . $redirect_script;
    

    However this resulted in a return URL that looked like http://example.com//cgi-bin/redirect.cgi -- note the "//" after example.com. When I removed the double-slashes from this URL, it worked again. OP, I see that your redirect URL has the same thing in /facebook/callback//empty?etc which I believe is what's messing it up.

    0 讨论(0)
提交回复
热议问题