Huawei Mobile Services In-app Purchases failed to load products once published in AppGallery - in-app-purchase

I integrated the HMS Core In-App Purchase service, and it works as expected in the sandbox test environment. However, the moment that I publish to the Huawei AppGallery, none of my products load and I get an error "failed to get data". I've done a few tests to see what the issue could be, and I'm pretty sure the code has been setup correctly. The problem always occurs once the app gets upload to AppGallery, and I'm starting to think that's where the problem is. Does anyone have any ideas on what's going on here?

Please check as follows:
Ensure that the certificate fingerprint has been configured, and the certificate for packing the signature on the local client is the same as the certificate for configuring the fingerprint in AppGallery Connect.
Please check that your service location is the same as the location where your HUAWEI ID was registered. To check the registration location, go to Account center > Settings > About. To check your service location, go to AppGallery > Me > Settings > Country/Region.
To give more precise solution, please provide the log.

This might be an app signature issue. Please check the documentation for App Signing.
https://developer.huawei.com/consumer/en/doc/development/AppGallery-connect-Guides/agc-app_bundle
App Signing automatically generates a signature key which will automatically override the signature of any APK you submit. If you signed your app with your local keystore and registered it as the signature you're using for your app with App Signing is enabled, there will be a signature mismatch. AppGallery will write over the signature you put on your APK and put the one that is generated with App Signing.
Here are two separate solutions for this issue. Use the one that works the best for you.
Make sure the signature key that is registered to your app is the one generated by App Signing.
Disable App Signing.

Related

App Center iOS build unable to verify integrity

I'm working on a Xamarin application and I'm doing iOS builds to run and test on different devices using App Center.
Everything was ok, on Apple Developer I created the Ad-Hoc certificate, the provisioning file, and the identifier and it was all good.
During the last implementation, I added on Entitlements the Associated Domain due to enabling the possibility to use the App Link and let the user open the application using a link provided via email.
I updated the Identifier adding the feature also to it and I downloaded it and uploaded it again to the dedicated branch on App Center, but now when I try to download the app to the device I receive this message:
Unable To Install "App Name". This app cannot be installed because its integrity could not be verified.
I tried different ways trying to solve it:
Create a completely new certificate with a new identifier, provisioning, and .p12 file
Checked Entitlement feature list correspond to the identifier list on Apple Developer
Used different versions of SDK and Xcode on App Center
I already searched around on the web but they talk about the provisioning file list but I already checked and it is updated.
Thank you for your help and for your suggestions.

Key Chain Data loss when app distribute through MDM

In our iPad application user has to enter his details for registration. After the user enters his details we save those details in the Device's keychain.
So next time the user launched the app user can use the app without registering again. Since we save it in the keychain even the app reinstall by deleting is also worked fine.
One of our clients uses their MaaS360 MDM to distribute this app to their users. But when the user installs it through the MDM app and after the next day, keychain data got lost and ask the user to do device registration again.
Initially, we thought this is due to one of the policies they have included. But no luck. Can someone please tell me what has happened here and how to solve this issue.
There are two possible scenarios:
First scenario:
It's a configuration issue of MaaS360 MDM server. Please look at these config examples.
Second scenario:
It's not a MaaS360 MDM issue, it's rather a certificate issue. Probably, your client gets the similar error when he/she is distributing an app:
"Could not find a valid private-key/certificate pair for this profile in your keychain."
Apple documentation says the following about that:
This error message indicates that your system’s Keychain is missing either the public or private key for the certificate you are using to sign your application. This often happens when you are trying to sign and build your application from a different system than the one you originally used to request your code signing certificate. It can also happen if your certificate has expired or has been revoked. Ensure that your app’s provisioning profile contains a valid code signing certificate, and that your system’s Keychain contains that certificate, the private key originally used to generate that certificate, and the WWDR Intermediate Certificate.
Please read Code Signing instructions to find out how to get rid of that issue.

iOS certificated on developer account and their role in App building

I have been an android developer and was thinking the life is not easy but then I found the iOS developer account and its relativity with project creation and other certifications.
I have developed the app, then in that App, I need to add FCM notifications. For this, I have installed FCM pod. And made necessary changes in the project.
Now its turn for me to connect my project with FCM ios ( and ios APNS with FCM server)
So good so far. Now I want to create a different team for this project. But When I create a distribution certificate it always creates a file with the name of the team I was using before i.e ABCD. I tried to create another profile but it just creates ABCD named file.
Can anyone tell what could be the problem?
2nd what are the steps required to create a production certificate for FCM to launch the app in the store?
Please discuss the first point in detail why it is happening? Why I can't change the name of the certificate.
Note: Whenever I try to create a development certificate it take another name
Please let me know what is going on..........
Xcode generates certificate fully automatic these days. You should let it automatically build them for you till you experienced more with apple signing process.
you can change any identifiers you want before sending any kind of build to appStore, (for example for test flight)
If you didn't upload to appstore yet, you can just login with your other account in Xcode and choose it from the team dropdown in signing section of general tap in Xcode. Then Xcode tries to sign the app with new credentials.
For FCM, follow the original documentation of FCM.
And at the end, Welcome to iOS world ;)

Xcode Signing - Failed to create provisioning

Here's the story:
I created a free developer account to build an app for a client.
I used this info for the Identity and Signing:
It came time to upload the app to TestFlight and to use the client's developer account.
I created the account in xcode using their apple id and updated the signing like so:
But now I got this error.
It was clear, so I updated the Bundle Identifier to this:
But again, now I am getting a different error, and I don't know what to do.
I do not have an iOS device to register, nor do I care to get one, since I'm not doing the testing - they are.
I did create an app in the App Store Connect, and it is set up like so:
As you can see I created it to match the Bundle ID from before and still no luck.
Any help is greatly appreciated. I just want to be able to get my Xcode project onto TestFlight using someone else's developer account (with their consent of course).
It needs to have at least one iOS device registered in order to create the development profile. Ask your client for the UDID of one of their devices and add that manually to the developer portal. If they don't have one handy, feel free to use: f978c5f2e861f71b340125a4fa8d130a6254a0b3 which will work.
Alternatively, switch to manual signing and do everything manually. That's my preferred method, but some say Xcode is finally good at managing profiles etc for you.
The only way to do this without a device is to turn off "Automatically manage signing" and manage everything at the Member Center.
You will need the distribution identity / certificate first. If the team already has one, you will need them to export it to you; otherwise you cannot upload.
Then register the app.
Then make a development certificate, and a distribution certificate for the app store, and download and install them.
Now you can archive and then export to the app store.

Update new APNS certificate to GCM

Generated new certificates in Apple Developer Centre.
It's weird i couldn't upload that certificates to GCM and also i couldn't see UPDATE button developer website.
It shows error {{ controller.errorMessage }}
How do I do that? Here's a screenshot of the Google Developer
You would have to import your GCM project to the Firebase Console (there won't be any changes, see my answer here) and update the certs from there.
While already importing, I would strongly advise toigrate your app(s) to start using FCM.
Same issue I was facing and able to solve !
Background : In my scenario we have an iOS App in the store and all our push notification configured through Google GCM (We were not using FCM). But we had situation where our APNS certificate is just about to get expired and we don't want to make any iOS Release(We had around 4k DAU on the current version)
Once certificate was expired any Notification we sent was throwing InvalidApnsCredentialfrom GCM.
Here is how to get out of this.
Configure you Firebase project. (Make sure you're logged into right Google account - the one you configured for setting up your GCM)
Goto : https://firebase.google.com > GET STARTED
Choose Import Google Project
You must see now all the GCM Project as below - If your logged in with correct account.
Choose the project.
Now your Firebase project is ready. It should look like below.
To Update new certificate.
Choose Setting gear at Overview.
Choose Project Settings
Now choose Cloud Messaging Tab & now you APNs Certificate section is visible.
If Certificate already expired - you must see RED flagged cell with UPLOAD & DELETE options. Upload new APNs certificate using * UPLOAD*.
You got better way to do it, please share your thoughts ! Cheers !

Resources