none
In-App Purchase - Accessing public certificate

    Question

  • 1. I created Windows Phone 8 beta app and submitted it to store.

    2. I created Consumable in-app products for the app.

    3. I purchase product from the app using in-app purchase interfaces and get a receipt with certificate id.

    4. I try to access for public certificate using certificate id from receipt but I get "404 - File or directory not found." message from https://lic.apps.microsoft.com/licensing/certificateserver/?cid=<CertificateId>

    - I used http://go.microsoft.com/fwlink/?LinkId=246509&cid=<CertificateId> address that forwarded the request on above page.

    Question is what I do wrong? It is hard for me to verify that our in-app purchase with server-side receipt verification works if I cannot access for public certificate.

    Monday, August 26, 2013 12:25 PM

All replies

  • I am going to move this to the publishing forum.

    Matt Small - Microsoft Escalation Engineer - Forum Moderator
    If my reply answers your question, please mark this post as answered.

    NOTE: If I ask for code, please provide something that I can drop directly into a project and run (including XAML), or an actual application project. I'm trying to help a lot of people, so I don't have time to figure out weird snippets with undefined objects and unknown namespaces.

    Tuesday, August 27, 2013 1:25 PM
  • Hello Seepia,

    Would you please explain what you are trying to accomplish in step #4?

    CurrentApp.GetAppReceiptAsync | getAppReceiptAsync method

    This discussion may answer your question:

    In-App Purchase — Server-side receipt verification

    -Eric


    Windows Phone Developer Support

    Send us your feedback about the Dev Center

    Tuesday, August 27, 2013 5:39 PM
    Owner
  • My goal is to verify digital signature of the receipt. I have understood that I will need public certificate to verity the receipt. Within the receipt there is certificateId, and I have an address that I can request the public certificate from. In step #4 I presented that address. I have all the other pieces of the puzzle already figured out, but for some reason I cannot access to the public certificate from that address. If I try to request it, I will get answer that page does not found. And I am using the certificateId that is in receipt of the purchase I just made in my Windows Phone beta application.

    I am sure that I am doing something wrong, but I have not figured out what.

    Tuesday, August 27, 2013 6:32 PM
  • We studied little more the CertificateId that came with the receipt and it seems that it cannot be right.

    Here is CertificateId from receipt of beta app product.

    A656B9B1B3AA509EEA30222E6D5E7DBDA9822DCD

    How can I get right kind of CertificateId when using beta version of the application? I want to be able to test whole process before I send the application for review. Is it possible to get one?

    We have tested our server with example certificate that is used in http://msdn.microsoft.com/en-us/library/windows/apps/jj649137.aspx

    With example CertificateId we can access the public certificate from address

    https://go.microsoft.com/fwlink/p/?LinkId=246509&cid=b809e47cd0110a4db043b3f73e83acd917fe1336

    Tuesday, August 27, 2013 7:33 PM
  • Hi Seepia

    http://msdn.microsoft.com/en-us/library/windows/apps/jj649137.aspx - this link is for Windows Store apps payments verification where you need to retrieve public certificates with the link you mentioned:

    https://go.microsoft.com/fwlink/p/?LinkId=246509&cid=b809e47cd0110a4db043b3f73e83acd917fe1336

    But for Windows Phone 8 apps you shouldn't download it but use the one provided with this sample http://code.msdn.microsoft.com/wpapps/In-app-purchase-receipt-c3e0bce4

    as it always would be the same with id: A656B9B1B3AA509EEA30222E6D5E7DBDA9822DCD

    Monday, September 16, 2013 2:19 PM
  • And by the way this page http://blogs.msdn.com/b/lighthouse/archive/2013/08/28/faqs-about-in-app-purchase-for-windows-phone-8.aspx contains the receipt for Windows Phone 8 which pases the signature checking

    Monday, September 16, 2013 2:27 PM