Error 7014 is a mobile gateway RPC exception caused by Security Guard misconfiguration. This topic describes the most common causes and how to fix them.
Problem description
The log shows an RPC exception with code 7014.
Solution
Security Guard
-
Verify the packaging configuration in the app's
build.gradlefile.signingConfigs { release { keyAlias 'mpaas123' keyPassword 'mpaas123' storeFile file('keystore/custom_title.jks')// Use the .jks suffix for the signature file. The .kstore suffix may cause a loading screen with three blue dots to appear when you open a miniapp. storePassword 'mpaas123' } debug { keyAlias 'mpaas123' keyPassword 'mpaas123' storeFile file('keystore/custom_title.jks') storePassword 'mpaas123' } } buildTypes { release { minifyEnabled false shrinkResources false // Set this to false to temporarily disable resource obfuscation for debug and release builds. proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro', 'mpProguard.cfg' } }NoteThe build type of the test package must match the build type of the APK package that you upload to the mPaaS console. For example, if you upload a release APK, use a release package for testing.
-
Confirm that the keep rule for Security Guard is added to the obfuscation configuration.
If the keep rule is missing, see Add obfuscation configuration. Add the keep rule, rebuild the app, and verify that the
drawable/yw_1222Security Guard image is generated. -
If you use Android Studio with Gradle 4.2 or later, add the
android.enableResourceOptimizations=falseproperty to thegradle.propertiesfile.dependencies { classpath "com.android.tools.build:gradle:4.1.1" classpath 'com.android.boost.easyconfig:easyconfig:2.8.4' } # In Android Studio 4.2, resource obfuscation for the Security Guard image causes error 7014. # Disable resource optimization to resolve the issue. android.enableResourceOptimizations=false If error
7014persists after completing these checks, re-upload the APK, download the configuration file, reimport it, and test again.