Oauth 2.0 使用Google集成casoauth

Oauth 2.0 使用Google集成casoauth,oauth-2.0,cas,google-oauth,Oauth 2.0,Cas,Google Oauth,我已将CAS 3.5.2服务器配置为具有OAuth客户端支持,我已成功使用Facebook进行身份验证,现在我想将其扩展为具有Google支持,我正在执行与Facebook相同的操作,即提供客户端ID和密码,但我收到了此错误 <Failed to get user data, code : 404 / body : <!DOCTYPE html> <html lang=en> <meta charset=utf-8> <meta name

我已将CAS 3.5.2服务器配置为具有OAuth客户端支持,我已成功使用Facebook进行身份验证,现在我想将其扩展为具有Google支持,我正在执行与Facebook相同的操作,即提供客户端ID和密码,但我收到了此错误

 <Failed to get user data, code : 404 / body : <!DOCTYPE html>
<html lang=en>
  <meta charset=utf-8>
  <meta name=viewport content="initial-scale=1, minimum-scale=1, width=device-width">
  <title>Error 404 (Not Found)!!1</title>
  <style>
    *{margin:0;padding:0}html,code{font:15px/22px arial,sans-serif}html{background:#fff;color:#222;padding:15px}body{margin:7% auto 0;max-width:390px;min-height:180px;padding:30px 0 15px}* > body{background:url(//www.google.com/images/errors/robot.png) 100% 5px no-repeat;padding-right:205px}p{margin:11px 0 22px;overflow:hidden}ins{color:#777;text-decoration:none}a img{border:0}@media screen and (max-width:772px){body{background:none;margin-top:0;max-width:none;padding-right:0}}
  </style>
  <a href=//www.google.com/><img src=//www.google.com/images/errors/logo_sm.gif alt=Google></a>
  <p><b>404.</b> <ins>That’s an error.</ins>
  <p>The requested URL <code>/api/people/@me/@self</code> was not found on this server.  <ins>That’s all we know.</ins>

如果有人能给我指出正确的方向,我将非常感激。

我是OAuth支持CAS的创建者

谷歌已经取消了对OAuth协议1.0版的支持,因此谷歌提供商不再工作

您应该升级到:

  • Google2Provider(如果使用CAS server 3.5.2,请使用scribe up 1.3.1依赖项,而不是scribe up 1.2.0)
  • Google2Client(如果使用CAS server 4.0.0,则使用pac4j oauth 1.4.0依赖项)