Issue
Problem Describe:
Recently, some developers have reported that they want to update their app(s) on Play Store, However, it receives rejection from Google with the title Implicit PendingIntent Vulnerability, said that their app(s) contain an Implicit PendingIntent issue. And they need to fix this issue before the deadlines shown in their Play Console, or app(s) may be removed from Google Play.
Similar Question: Google denied update due Remediation for Implicit PendingIntent Vulnerability
Solution
As@tao mentioned, let me post the solution here.
Problem Reason:
HMS Core Push kit earlier than 5.3.0.304 version、Analytics Kit earlier than 6.0.0.301 version and Account kit earlier than 5.3.0.305 version contain the Implicit PendingIntent issue.
Solution:
Push Kit SDK version 5.3.0.304、Analytics Kit SDK version 6.0.0.301 and Account kit SDK version 5.3.0.305 have been released and fixed the Implicit PendingIntent issue. They've been tested and verified by developers and can be approved by Google for release.
If you are currently using the plug-in(such as React Native, Cordova, Ionic,Flutter), Before the new version of those plug-in released, Huawei also provide a workaround solution(By manually changing the version number).
The following describes the modification method (based on the 5.x plug-in):
- React Native:
After the HMS Core plug-in is installed in the RN, the plug-in package is stored in node_modules/@hmscore.
You need to modify the
build.gradlefile in the node_modules/@hmscore/react-native-hms-account/android directory (taking the Account Kit plug-in as an example):Open the
build.gradlefile and change the SDK version in dependencies.
dependencies {
implementation fileTree(dir: "libs", include: ["*.jar"])
implementation 'com.facebook.react:react-native:+' // From node_modules
implementation 'com.huawei.hms:hwid:5.0.3.302'
}
After the update, run the following command to start compilation again. The plug-in downloads the new SDK:
react-native run-android
- Cordova/Ionic
If you have installed the plugin as Huawei document describred, the plugin should be saved in node_modules/@hmscore folder.
You need to modify the
plugin.xmlfile in thenode_modules/@hmscore/cordova-plugin-hms-pushdirectory. (The following uses the Push Kit plug-in as an example)Open the
Plugin.xmlfile, search for the keywordframework, and find the SDK to be modified.
<framework src="androidx.core:core:1.3.1"/>
<framework src="com.facebook.fresco:fresco:2.2.0"/>
<framework src="com.huawei.hms:push:5.0.2.301" />
<framework src="resources/plugin.gradle" custom="true" type="gradleReference"/>
Change the version number to the new one and save it.
Go back to the application root directory and delete the
platforms/androidandplugins/cordova-plugin-hms-pushfolder.Run the following command in the root directory:
Cordova:
cordova platform add androidcordova run android --deviceIonic(Cordova):
ionic cordova platform add androidionic buildionic cordova run android --deviceIonic (Capacitor) operates in different ways:
①. Delete the
capacitor-cordova-android-pluginsfolder from the android directory.②. Modify the
plugin.xmlfile according to the description in step 2.③. Run the following command:
ionic buildnpx cap syncnpx cap open android④. Recompile in the Android Studio
Flutter
You may refer to this answer.
Summary
The plug-ins above are used in open source mode, so developers can modify them directly.
However, the Xamarin plug-in is published in Nuget Package mode. Therefore, you cannot modify the SDK version. If this problem occurs, please feel free to contact us.
Answered By - shirley





0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.