Skip to content
Snippets Groups Projects
Commit 68ce74b4 authored by Nick Kralevich's avatar Nick Kralevich Committed by Gerrit Code Review
Browse files

Merge "readme: add info on generating pem files from apks"

parents cdf54ba7 9793a452
No related branches found
No related tags found
No related merge requests found
...@@ -118,5 +118,16 @@ mac_permissions.xml: ...@@ -118,5 +118,16 @@ mac_permissions.xml:
via the familiar $VARIABLE syntax. This is often useful for setting a location via the familiar $VARIABLE syntax. This is often useful for setting a location
to ones release keys. to ones release keys.
Often times, one will need to integrate an application that was signed by a separate
organization and may need to extract the pem file for the insertkeys/keys.conf tools.
Extraction of the public key in the pem format is possible via openssl. First you need
to unzip the apk, once it is unzipped, cd into the META_INF directory and then execute
openssl pkcs7 -inform DER -in CERT.RSA -out CERT.pem -outform PEM -print_certs
On some occasions CERT.RSA has a different name, and you will need to adjust for that.
After extracting the pem, you can rename it, and configure keys.conf and
mac_permissions.xml to pick up the change. You MUST open the generated pem file in a text
editor and strip out anything outside the opening and closing scissor lines. Failure to do
so WILL cause a compile time issue thrown by insertkeys.py
NOTE: The pem files are base64 encoded and PackageManagerService, mac_permissions.xml NOTE: The pem files are base64 encoded and PackageManagerService, mac_permissions.xml
and setool all use base16 encodings. and setool all use base16 encodings.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment