Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Validation of transaction doesn't work ? #110

Open
StanKocken opened this issue Dec 8, 2012 · 0 comments
Open

Validation of transaction doesn't work ? #110

StanKocken opened this issue Dec 8, 2012 · 0 comments

Comments

@StanKocken
Copy link

Hi,

In my billing activity I put :

@Override
public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.billing);
    BillingController.registerObserver(mBillingObserver);
    BillingController.checkBillingSupported(this);
    BillingController.setSignatureValidator(this);
}

@Override
public void onDestroy() {
    super.onDestroy();
    BillingController.setSignatureValidator(null);
    BillingController.unregisterObserver(mBillingObserver);
}

I don't do anything within my "mBillingObserver"

I want to purchase an item (added in my google play account) :

BillingController.requestPurchase(this, purchaseId, false, null);

After my purchased, I can see a toast "Thanks for your purchased for the play store" and I'm called on my method :

@Override
public boolean validate(String signedData, String signature) {
    Log.i(TAG, "validate " + signedData);
    // when a purchased need to be checked, just return false if the server side check return false
    // TODO add the server side check here
    return false; // change it by the server side verification
}

in my logcat I can see
"Billing(16214): Validation failed"

But the purchased wasn't canceled : I received an email from google to thanks me for my purchased.

Note : I don't call any other method of BillingController anywhere

Is it an error from me or from the billing library ?

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant