私はGoogle Federated LoginをPremierアプリアカウントと統合しようとしていますが、いくつか問題があります。ホストされたアプリケーションのGoogle Federated Login(OpenID + Oauth) - エンドポイントの変更?
https://www.google.com/accounts/o8/ud
にすべてのパラメータ(下記参照)を送信すると、request_token
と、質問の対象となる属性の一覧がAttribute Exchange
で返されます。これは、アプリケーションデータベースにユーザーを格納するための属性exhange(AX)を使用する電子メールが必要で、将来、API requests to scopes
(つまりカレンダー、連絡先など)のリクエストトークンが必要なので、完璧です。
しかし、(本明細書endpoint
と呼ぶ)そのURLを使用することは問題であるそのホストされるアプリケーション(Gmail、カレンダー、ら)にログインしたユーザを保持しません。
エンドポイントをhttps://www.google.com/a/thedomain.com/o8/ud?be=o8
に変更すると、すべてが変更されます。私は自動的に他のGoogleアプリケーション(gmailなど)にサインインしています。ただし、そのエンドポイントを使用して、私はアタックトークンをまたはにのみ取得します。特にハイブリッドではないことは明らかです。それは非常に多くのものです。エンドポイントへの
例要求https://www.google.com/accounts/o8/ud
parameters = {
'openid.ns': 'http://specs.openid.net/auth/2.0',
'openid.claimed_id': 'http://specs.openid.net/auth/2.0/identifier_select',
'openid.identity': 'http://specs.openid.net/auth/2.0/identifier_select',
'openid.return_to':'http://our.domain.com/accounts/callback/',
'openid.realm': 'http://our.domain.com/',
'openid.assoc_handle': assoc_handle,
'openid.mode': 'checkid_setup',
'openid.ns.ext2': 'http://specs.openid.net/extensions/oauth/1.0',
'openid.ext2.consumer': 'our.domain.com',
'openid.ext2.scope': 'https://mail.google.com/mail/feed/atom',
'openid.ns.ax':'http://openid.net/srv/ax/1.0',
'openid.ax.mode':'fetch_request',
'openid.ax.required':'firstname,lastname,email',
'openid.ax.type.firstname':'http://axschema.org/namePerson/first',
'openid.ax.type.lastname':'http://axschema.org/namePerson/last',
'openid.ax.type.email':'http://axschema.org/contact/email',
}
return HttpResponseRedirect(end_point + '?' + urllib.urlencode(parameters))
(assoc_handleが以前にOpenIDの最初の要求により正常に設定された)
私が戦って、このHybirdアプローチの作業を取得しようとする日のために苦労してきましたほとんどの不透明なエラーメッセージ(This page is invalid
...ありがとうGoogle)と一貫したドキュメントの欠如。私はこの時点までに得ることができるすべてのコードサンプルをトラブルしました。どんな助けでも高く評価されるでしょう...