NameDateSize

..12-Mar-20154 KiB

android-config.mk12-Mar-20151.7 KiB

Android.mk12-Mar-2015506

android.testssl/12-Mar-20154 KiB

apps/12-Mar-20154 KiB

Apps-config-host.mk12-Mar-20152.2 KiB

Apps-config-target.mk12-Mar-20152.5 KiB

Apps.mk12-Mar-2015839

build-config-32.mk12-Mar-20151.5 KiB

build-config-64.mk12-Mar-20151.5 KiB

build-config-static-32.mk12-Mar-2015802

build-config-static-64.mk12-Mar-2015802

build-config-trusty.mk12-Mar-20152.3 KiB

check-all-builds.sh12-Mar-201515.1 KiB

CleanSpec.mk12-Mar-20154.1 KiB

crypto/12-Mar-20154 KiB

Crypto-config-host.mk12-Mar-201517.7 KiB

Crypto-config-target.mk12-Mar-201517.9 KiB

Crypto-config-trusty.mk12-Mar-20156.4 KiB

Crypto.mk12-Mar-20152.4 KiB

e_os.h12-Mar-201523.2 KiB

e_os2.h12-Mar-201510.2 KiB

import_openssl.sh12-Mar-201521.1 KiB

include/12-Mar-20154 KiB

MODULE_LICENSE_BSD_LIKE12-Mar-20150

NOTICE12-Mar-20156.1 KiB

openssl.config12-Mar-201521.1 KiB

openssl.trusty.config12-Mar-20155.5 KiB

openssl.version12-Mar-201523

patches/12-Mar-20154 KiB

README.android12-Mar-20153.4 KiB

rules.mk12-Mar-20151.1 KiB

ssl/12-Mar-20154 KiB

Ssl-config-host.mk12-Mar-20152.1 KiB

Ssl-config-target.mk12-Mar-20152.4 KiB

Ssl.mk12-Mar-20152.2 KiB

README.android

1OpenSSL on the Android platform.
2---
3
4The code in this directory is based on $OPENSSL_VERSION in the file
5openssl.version. See patches/README for more information on how the
6code differs from $OPENSSL_VERSION.
7
8Porting New Versions of OpenSSL.
9--
10
11The following steps are recommended for porting new OpenSSL versions.
12
131) Retrieve the appropriate version of the OpenSSL source from
14   www.openssl.org/source (in openssl-*.tar.gz file). Check the PGP
15   signature (found in matching openssl-*.tar.gz.asc file) with:
16
17     gpg openssl-*.tar.gz.asc
18
19   If the public key is not found, import the the one with the
20   matching RSA key ID from http://www.openssl.org/about/, using:
21
22     gpg --import # paste PGP public key block on stdin
23
242) Update the variables in openssl.config and openssl.version as appropriate.
25   At the very least you will need to update the openssl.version.
26
273) Run:
28
29     ./import_openssl.sh import openssl-*.tar.gz
30
314) If there are any errors, then modify openssl.config, openssl.version
32   and patches in patches/ as appropriate.  You might want to use:
33
34     ./import_openssl.sh regenerate patches/*.patch
35
36   Repeat step 3.
37
385) Cleanup before building with:
39
40     m -j16 clean-libcrypto clean-libssl clean-openssl clean-ssltest
41
426) Build openssl from the external/openssl directory with:
43
44     mm -j16 snod && adb remount && adb sync system
45
46   If there are build errors, then patches/*.mk, openssl.config, or
47   android-config.mk may need updating.
48
497) Run tests to make sure things are working:
50
51     # Run local openssl tests
52     (cd android.testssl/ && ./testssl.sh)
53     # Build and sync libcore tests
54     (croot && cd libcore && mm -j16 snod && adb remount && adb sync)
55     # Run tests from libcore
56     (croot && vogar --classpath out/target/common/obj/JAVA_LIBRARIES/core-tests_intermediates/classes.jar javax.net.ssl tests.api.javax.net)
57     # Run tests from Harmony
58     (croot && vogar --classpath out/target/common/obj/JAVA_LIBRARIES/apache-harmony-tests_intermediates/classes.jar tests.api.java.math.BigIntegerTest org.apache.harmony.tests.java.math)
59     # try an https website
60     adb shell am start https://online.citibank.com # confirm result in browser
61
62     The vogar tool can be found externally at http://code.google.com/p/vogar/
63
64     Quick installation instructions (without rebuilding from source):
65        VOGAR=$HOME/vogar
66        svn co http://vogar.googlecode.com/svn/trunk/ $VOGAR
67        mkdir -p $VOGAR/build/
68        curl -o $VOGAR/build/vogar.jar https://vogar.googlecode.com/files/vogar.jar
69        PATH=$PATH:$VOGAR/bin
70
71     Within Google, you can find it under:
72       /home/dalvik-prebuild/vogar/bin/vogar
73
74     # You can also run openssl s_server as a test server on the device:
75     adb push ./android.testssl/CAss.cnf /sdcard/CAss.cnf
76     adb shell openssl req -config /sdcard/CAss.cnf -x509 -nodes -days 365 -subj '/C=US/ST=California/L=Mountain View/CN=localhost' -newkey rsa:1024 -keyout /sdcard/server.pem -out /sdcard/server.pem
77     adb shell openssl s_server -cert /sdcard/server.pem -www -verify 1
78     adb shell am start https://localhost:4433 # confirm result in browser
79
808) Do a full build before checking in:
81
82     m -j16
83
84Optionally, check whether build flags (located in CONFIGURE_ARGS in
85openssl.config, plus some extras in android-config.mk), need to be updated.
86Doing this step will help ensure that the compiled library is appropriately
87optimized for speed and size.
88