谷歌同意屏幕没有按预期显示 [英] Google consent screen not shown as expected

查看:335
本文介绍了谷歌同意屏幕没有按预期显示的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在cloud.google.com上注册了一个web应用程序。 OAuth 2.0客户端ID如下所示:



我使用grails和grails oauth插件。在Config.groovy中,我添加了以下代码片段:

  google {
api = GoogleApi
key =' xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx.apps.googleusercontent.com'
secret ='yyyyyyyyyyyyyyyyyyyyyyyy'
$ b $ scope ='https://www.googleapis.com/auth/userinfo.profile'

callback =http:// localhost:8080 / grailsOauthPluginDemo / oauth / google / callback
successUri =http:// localhost:8080 / grailsOauthPluginDemo / oauthCallBack / google
failureUri =http :// localhost:8080 / grailsOauthPluginDemo / oauthCallBack / failure
}

以下内容into index.gsp

 < oauth:connect provider =google> Google< / oauth:connect>< br /> 

我使用我的个人Google帐户登录。我使用的是 https://github.com/manishkbharti/grailsOauthPluginDemo ,当点击Google链接I进入同意页面,如下所示:



我期待使用我的应用程序名称来获取类似于以下内容的页面。我知道我必须添加图片,但应用程序名称应该弹出。

解决方案

我相信grailsOauthPluginDemo正在使用 Google的OAuth1.0a API

目前在同意页面中使用不同的模板。



希望有帮助!


I have registered a web application at cloud.google.com. "The OAuth 2.0 Client ID" looks like this:

I am using grails and the grails oauth plugin. In Config.groovy I added the follwoing snippet:

google {
    api = GoogleApi
    key = 'xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx.apps.googleusercontent.com'
    secret = 'yyyyyyyyyyyyyyyyyyyyyyyy'

    scope = 'https://www.googleapis.com/auth/userinfo.profile'

    callback = "http://localhost:8080/grailsOauthPluginDemo/oauth/google/callback"
    successUri = "http://localhost:8080/grailsOauthPluginDemo/oauthCallBack/google"
    failureUri = "http://localhost:8080/grailsOauthPluginDemo/oauthCallBack/failure"
}

and the following into index.gsp

<oauth:connect provider="google">Google</oauth:connect><br/>

I am logged in with my personal google account. I am using the https://github.com/manishkbharti/grailsOauthPluginDemo and when clicking the Google link I get to the consent page which looks like this:

I was expecting to get a page looking something like the following with my applications name. I know that I have to add a picture but the applications name should popup.

解决方案

I believe that the grailsOauthPluginDemo is using Google's OAuth1.0a API which currently uses different templates for the consent page.

Hope that helps!

这篇关于谷歌同意屏幕没有按预期显示的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆