如何验证我的 google web store 应用程序是否已使用 asp.net 获得许可?

发布于 2024-12-13 01:14:48 字数 309 浏览 0 评论 0原文

我正在使用 DotNetOpenAuth.dll 来获取用户 ID,但我不知道如何发送 google 需要的签名 OAuth 请求:

http://code.google.com/intl/it-IT/chrome/webstore/docs/check_for_ payment.html

该示例仅显示 java代码

谢谢寻求任何帮助

I'm using DotNetOpenAuth.dll in order to obtain userid, but i don't know how to send the signed OAuth request google needs:

http://code.google.com/intl/it-IT/chrome/webstore/docs/check_for_payment.html

the example shows only java code

thanks for any help

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

撩发小公举 2024-12-20 01:14:48

转到 http://www.dotnetopenauth.net/ 并阅读文档,您应该在那里找到您需要的所有内容。

编辑:
我不确定这是否是正确的方法,但这里有一些 c# 示例代码

var serviceProvider = new ServiceProviderDescription();
var tokenManager = new TokenManager(); //make an implementation of IConsumerTokenManager
var oauth = new WebConsumer(serviceProvider, tokenManager); //instanciate an consumer
var user = new User(); //User class contains an implementation of getFederatedIdentity()
var url = new Uri(string.Format(SERVER_URL,APP_ID,HttpUtility.HtmlEncode(user.getFederatedIdentity())));//create the url
var response = oauth.PrepareAuthorizedRequestAndSend(
    new MessageReceivingEndpoint(url, HttpDeliveryMethods.AuthorizationHeaderRequest), TOKEN); //Send the request
//do what you want with the response

Go to http://www.dotnetopenauth.net/ and read the documentations, you should find everything you need there.

EDIT:
I'm not sure if this is the right way or not but here is some sample code in c#

var serviceProvider = new ServiceProviderDescription();
var tokenManager = new TokenManager(); //make an implementation of IConsumerTokenManager
var oauth = new WebConsumer(serviceProvider, tokenManager); //instanciate an consumer
var user = new User(); //User class contains an implementation of getFederatedIdentity()
var url = new Uri(string.Format(SERVER_URL,APP_ID,HttpUtility.HtmlEncode(user.getFederatedIdentity())));//create the url
var response = oauth.PrepareAuthorizedRequestAndSend(
    new MessageReceivingEndpoint(url, HttpDeliveryMethods.AuthorizationHeaderRequest), TOKEN); //Send the request
//do what you want with the response
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文