简体   繁体   English

如何使用PHP验证用户的Google令牌ID?

[英]How can I verify user's Google Token ID with PHP?

I want to let my user log in on my website using his Google Account. 我想让我的用户使用他的Google帐户登录我的网站。 I know that using this function on JS you can get a Token ID: 我知道在JS上使用此功能可以获取令牌ID:

var id_token = googleUser.getAuthResponse().id_token;

How to verify that his token is ok using PHP? 如何使用PHP验证他的令牌正常? I can't find something to help me. 我找不到可以帮助我的东西。

您应该使用“知名商品”或“ 信赖方认证图书馆,而不要按照@Honsa Stunna的建议重新发明轮子。

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

相关问题 如何使用 Javascript 在 Firestore 中验证用户的 ID 令牌? - How to verify a user's ID token in firestore using Javascript? 在 Expo 中使用 Firebase 验证 Google 提供的 ID Token - Verify ID Token provided by Google with Firebase in Expo 使用 Node js 验证 Google ID 令牌 - Verify Google ID Token with Node js PHP - 验证每个请求的用户令牌 - PHP - Verify user token on every request 无论如何,有没有验证Google电子表格ID的信息? - Is there anyway to verify a google spreadsheets ID's 如何使命令 !say 与用户的 ID 一起使用? - How can I make the command !say work with a user's id? 如何在加载 dom 之前验证用户令牌? - How to verify user token before the dom is loaded? 如何在同一字段的两个用户 ID 中获取第二个用户 ID - How can I get the second user Id in a two user id's in the same field 使用谷歌登录无法从 firebase 获取“电子邮件”验证 id 令牌 - Not getting "email" from firebase verify id token using google sign in 如何在服务器端(Node.js)以编程方式验证Facebook用户的访问令牌? - How to verify a Facebook user's access token programmatically on the server-side (Node.js)?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM