Android mobile guard-signature file description & package Name Description, android guard
In the article "Android mobile guard-pack and generate an apk to maintain the server", the new apk version is implemented to the server. When the client apk is opened, a new version is found, prompting for updates. The xutils tool is also used to download the apk from the server.
URL: http://www.cnblogs.com/wuyudong/p/5903484.html.
This article downloads the installation of the local apk, the process is very simple, refer to Android APK Installation
The Code is as follows:
/*** Install the corresponding apk * @ param file Installation File */protected void installApk (file) {// system application interface, source code, import Intent intent = new Intent (); intent. setAction ("android. intent. action. VIEW "); intent. addCategory ("android. intent. category. DEFAULT "); intent. setDataAndType (Uri. fromFile (file), "application/vnd. android. package-archive "); startActivity (intent );}
After running the project
Click to install
Installation failed. Please note that
Apk Installation Considerations
Upgrade
1. Note: overwrite the original application with the same package name.
2. Consistent signatures ???
Applications running from Eclipse to mobile phones use applications under the bin directory and debug. keystore signature applications
Mobile guard version 1, right-click to run to the mobile phone, so the signature is debug. keystore
Mobile guard version 2, which is packaged separately, generates the corresponding signature file wuyudongkeystore
Generate a wuyudongkeystore apk as the signature file
After performing the preceding operations, you can solve the problem.
PS:
Consistent signatures and different package names: generate two mobile guard apk, and the package name is the unique identifier of the application
Different signatures make the package name consistent: overwrite Installation failed
1.0 generate a keyStore
2.0 ...... Use the existing keyStore and password.
Secure keyStore + Password