简体   繁体   English

喜欢页面时,应用程序不拥有Azure ACS Facebook错误191 redirect_uri不属于应用程序

[英]Azure ACS Facebook Error 191 redirect_uri is not owned by the application when Liking a page

I'm using the Facebook C# SDK to post a Like to Facebook from my ACS-secured web application but I'm getting the error: 我正在使用Facebook C#SDK从受ACS保护的Web应用程序中向Facebook发布“赞”,但出现错误:

API Error Code: 191 API错误代码:191
API Error Description: The specified URL is not owned by the application Error Message: redirect_uri is not owned by the application. API错误说明:指定的URL不归应用程序所有错误消息:redirect_uri不归应用程序所有。

I believe the reason for this is because the url for the page I'm liking does not match the Facebook App Domain. 我相信这是因为我喜欢的页面的网址与Facebook App Domain不匹配。

Details: 细节:

  • The page I'm trying to "Like" is (for example) http:// mysite.com/Story.aspx. 我尝试“赞”的页面是(例如)http:// mysite.com/Story.aspx。

  • In ACS, the link to my secure login page is https:// mysite-acs.accesscontrol.windows.net/. 在ACS中,指向我的安全登录页面的链接是https:// mysite-acs.accesscontrol.windows.net/。

  • In Facebook, my app domain is mysite-acs.accesscontrol.windows.net and the Site URL under the "Website with Facebook Login" is: https:// mysite-acs.accesscontrol.windows.net/ 在Facebook中,我的应用程序域是mysite-acs.accesscontrol.windows.net,“具有Facebook登录名的网站”下的站点URL是:https:// mysite-acs.accesscontrol.windows.net/

  • The page I'm liking has the correct "og" tags and is on an unsecured page. 我喜欢的页面具有正确的“ og”标签,并且位于不安全的页面上。

Is there any way I can get Facebook Like's working with ACS? 有什么办法可以使Facebook Like与ACS一起工作?

UPDATE: I've found a (temporary) solution. 更新:我已经找到了(临时)解决方案。

I've found a workaround that allows me to have multiple Facebook App Domains but it is definitely not a perfect solution. 我找到了一种解决方法,可以让我拥有多个Facebook App Domains,但这绝对不是一个完美的解决方案。 The workaround is to specify the ACS url and the site url in the App Domains box. 解决方法是在“应用程序域”框中指定ACS URL 站点URL。 Then, under Website with Facebook Login I've entered the ACS url in the Site URL box, then, under Mobile Web, I've entered the site url in the Mobile Site URL box. 然后,在具有Facebook登录名的网站下,在“站点URL”框中输入ACS URL,然后在“移动Web”下,在“移动站点URL”框中输入站点URL。 Now the link on Facebook works perfectly as Facebook can see the page on my site. 现在,Facebook上的链接可以正常工作,因为Facebook可以看到我网站上的页面。 I'm not going to mark the question as solved until I find the real solution, but hopefully it can help someone if they are stuck. 在找到真正的解决方案之前,我不会将问题标记为已解决,但希望它能对遇到困难的人有所帮助。 Thanks for your responses. 感谢您的回复。 Much appreciated! 非常感激!

This is where you need to use a CNAME to point to your Azure site if you can. 如果可以,您需要在此处使用CNAME指向您的Azure站点。 You do have conflicting domains which facebook will not allow. 您的网域确实存在冲突,facebook不允许这样做。 You can either add the accesscontrol.windows.net as your domain in Facebook or setup a CNAME in your DNS provider to point to accesscontrol.windows.net from 'mysite.com'. 您可以将accesscontrol.windows.net添加为Facebook中的域,也可以在DNS提供程序中设置CNAME以指向“ mysite.com”中的accesscontrol.windows.net。

Those are your options. 这些是您的选择。

Hope this helps! 希望这可以帮助!

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Facebook应用程序重定向到redirect_uri位置 - facebook application redirects to redirect_uri location Facebook OAuth redirect_uri不是绝对URI。 检查RFC 3986。\\“,\\”类型\\“:\\” OAuthException \\“,\\”代码\\“:191 - Facebook OAuth redirect_uri isn't an absolute URI. Check RFC 3986.\“,\”type\“:\”OAuthException\“,\”code\":191 改变facebook redirect_uri web api - change facebook redirect_uri web api 如何编码redirect_uri for facebook登录 - How to encode the redirect_uri for facebook login redirect_uri URL必须是绝对错误 - The redirect_uri URL must be absolute error IdentityServer4 无效的 Redirect_Uri 错误 - IdentityServer4 Invalid Redirect_Uri Error 如何获取用于Facebook应用程序集成C#的client_id,redirect_uri,代码和客户端密钥的access_token? - How to get access_token for a client_id, redirect_uri, code and client secret for Facebook application integration, C#? 在Win 8 App中使用Yammer时应该是redirect_uri - What should be the redirect_uri when using Yammer in Win 8 App 使用IIS虚拟目录时出现Facebook登录错误191 - Facebook Login Error 191 when use IIS Virtual Directory Facebook喜欢不喜欢正确的页面 - Facebook like not liking the proper page
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM