我已经使用java在应用程序引擎上部署了我的云端点。现在,我需要将对这些API的访问仅限于那些使用openid登录到我的web应用程序的web客户端。
我将创建自己的身份提供者,并希望使用用户身份访问GAE云端点。
因此,我需要一种机制来发出令牌,然后需要我的GAE云端点来验证该令牌,然后才向该客户端提供API服务。
到目前为止,我已经创建了云端点,并且它们是可公开访问的,这就是问题所在。
总括而言,我有以下问题:
发布于 2015-11-23 10:06:34
You can generate client Ids for web, android and IOS applications, and to allow api access to only genuine users you can use the User class object of the com.google.appengine.api.users
as a parameter to your api method and than check it for null value, if it is null it is not a valid user.
Or you can use the @apiMethod annotation of app engine and provide the cliendID parameter with the client ids of the genuine applications.`enter code here`https://stackoverflow.com/questions/31873608
复制相似问题