English 中文(简体)
Inpp 计费, 如何更新服务器侧边数据库
原标题:In-app billing, how to update server side database

当有人在我的 Android 应用程序中购买管理项目时, 我试图执行一个功能来更新我的服务器侧边数据库 。

Basically I want the user to be able to log on to my website when the managed item have been purchased but not before. Can someone please provide me with details on how to accomplish this. Someone I would like to send a username/email or similar to the web page that I can use to update the server database. However I need to make sure this cannot be sent by a user that have not purchased the managed item in my Android application

我读过一些关于这个议题的好文章,

最佳方面

最佳回答

Google 游戏商店发送签名数据和每个人购买的签名。 成功从您和机器人应用程序中购买一个项目时, 应用程序需要将签名的数据和签名发送到您的服务器上。 然后这些数据需要根据公用密钥进行验证。 成功验证后, 您可以在成功响应和他登录所需的证书中隐藏该和机器人应用程序。

EDIT :
Android Inapp Billing Overview
Sample Inapp Billing
Sample BroadcastReceiver

请检查应用中的鼠标开单执行中的样本和机器人样例。 这有一个地牢示例可以执行应用计单。 您需要执行一个广播接收器, 它将数据从 GooglePlay. com. android. vend. billing. PURCHASE_STATE_CHANGED 意向中获取回来。 现在您可以从此意向中获取签名的数据和签名 。

String signedData = intent.getStringExtra("inapp_signed_data");
String signature = intent.getStringExtra("inapp_signature");

现在您可能需要将此数据传送到您的服务器, 以识别实际购买该数据的用户。 希望它有所帮助 。

问题回答

暂无回答




相关问题
Brute-force/DoS prevention in PHP [closed]

I am trying to write a script to prevent brute-force login attempts in a website I m building. The logic goes something like this: User sends login information. Check if username and password is ...

please can anyone check this while loop and if condition

<?php $con=mysql_connect("localhost","mts","mts"); if(!con) { die( unable to connect . mysql_error()); } mysql_select_db("mts",$con); /* date_default_timezone_set ("Asia/Calcutta"); $date = ...

定值美元

如何确认来自正确来源的数字。

Generating a drop down list of timezones with PHP

Most sites need some way to show the dates on the site in the users preferred timezone. Below are two lists that I found and then one method using the built in PHP DateTime class in PHP 5. I need ...

Text as watermarking in PHP

I want to create text as a watermark for an image. the water mark should have the following properties front: Impact color: white opacity: 31% Font style: regular, bold Bevel and Emboss size: 30 ...

How does php cast boolean variables?

How does php cast boolean variables? I was trying to save a boolean value to an array: $result["Users"]["is_login"] = true; but when I use debug the is_login value is blank. and when I do ...

热门标签