【问题标题】:Javascript not enabled error in Firefox and Chrome while using Google Oauth使用 Google Oauth 时 Firefox 和 Chrome 中的 Javascript 未启用错误
【发布时间】:2012-10-26 02:04:04
【问题描述】:

我正在为 liferay 用户尝试 google oAuth 身份验证。用于 Google OAuth 的 URL 是

https://accounts.google.com/o/oauth2/auth?client_id=myClientId&redirect_uri=http://localhost:8090/c/login/oauth2callback&response_type=code&scope=https://www.googleapis.com/auth/userinfo.profile+https://www.googleapis.com/auth/userinfo.email

它将我重定向到谷歌登录页面(如果用户未登录),然后是授权页面。

在我说允许后,浏览器将我重定向到

https://accounts.google.com/o/noscript

You've reached this page because we have detected that Javascript is disabled in your browser. The page you attempted to load cannot display properly if scripts are disabled.

Please enable scripts and retry the operation or go back in your browser

它只发生在 Firefox(我使用 16.0.2,即使在早期版本中也发生过)和 chrome(22)。它在 IE 中运行良好。

这里有什么问题?

【问题讨论】:

    标签: javascript redirect login oauth


    【解决方案1】:

    一种可能性是一些扩展阻塞js, 如果 oAuth OK,请在隐身窗口中重试: 对于最新安装的扩展,您可以选择“允许隐身”,然后尝试隐身查看,如果 oAuth 失败,则删除扩展。 刚刚找到一个奇怪的扩展,删除它,然后OK!

    【讨论】:

      【解决方案2】:

      你试过enable scripts in Chrome吗?

      【讨论】:

      • 感谢您的回复。是的,两个浏览器都启用了 javascript,而且这在 IE 中有效,但在其他浏览器中无效,为什么?
      • 好吧,localhost:8090/c/login/oauth2callback 中的某些东西使用了导致 Firefox 和 Chrome 阻止它的脚本。在 IE 上,您可能已经允许在其他设备上禁用的东西 - 配置检查,我的朋友...
      【解决方案3】:

      原因是您的配置设置不够好。转到 Mozilla 中的 about:config,然后转到 VERY 最后一个,然后将其设置为 0。

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 2012-06-30
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 2012-01-29
        • 1970-01-01
        相关资源
        最近更新 更多