diff options
author | Kenny Root <kroot@google.com> | 2012-11-14 14:17:34 -0800 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2012-11-14 14:17:35 -0800 |
commit | 2a8ef4f8fafad04f8ab2d5162b063f166221ed45 (patch) | |
tree | ee62277d7e584b6d1a628aa0ae0ff712873c166c | |
parent | e9780b9481b88ef37fdac2a0171e50cab6112781 (diff) | |
parent | 184b3bc9cbce3ee4cce79c24c69800722f3f0df2 (diff) | |
download | wpa_supplicant_6-2a8ef4f8fafad04f8ab2d5162b063f166221ed45.tar.gz |
Merge "Switch keystore to binder"jb-mr1-dev-plus-aosp
-rw-r--r-- | wpa_supplicant/Android.mk | 2 | ||||
-rw-r--r-- | wpa_supplicant/src/crypto/tls_openssl.c | 7 |
2 files changed, 5 insertions, 4 deletions
diff --git a/wpa_supplicant/Android.mk b/wpa_supplicant/Android.mk index 2706193..64d37b7 100644 --- a/wpa_supplicant/Android.mk +++ b/wpa_supplicant/Android.mk @@ -1125,7 +1125,7 @@ endif ifneq ($(BOARD_WPA_SUPPLICANT_PRIVATE_LIB),) LOCAL_STATIC_LIBRARIES += $(BOARD_WPA_SUPPLICANT_PRIVATE_LIB) endif -LOCAL_SHARED_LIBRARIES := libc libcutils libcrypto libssl +LOCAL_SHARED_LIBRARIES := libc libcutils libcrypto libssl libkeystore_binder LOCAL_CFLAGS := $(L_CFLAGS) LOCAL_SRC_FILES := $(OBJS) LOCAL_C_INCLUDES := $(INCLUDES) diff --git a/wpa_supplicant/src/crypto/tls_openssl.c b/wpa_supplicant/src/crypto/tls_openssl.c index 70fe79c..3e5d8ca 100644 --- a/wpa_supplicant/src/crypto/tls_openssl.c +++ b/wpa_supplicant/src/crypto/tls_openssl.c @@ -49,16 +49,17 @@ #ifdef ANDROID #include <openssl/pem.h> -#include "keystore_get.h" +#include <keystore/keystore_get.h> static BIO *BIO_from_keystore(const char *key) { BIO *bio = NULL; - char value[KEYSTORE_MESSAGE_SIZE]; - int length = keystore_get(key, strlen(key), value); + uint8_t *value = NULL; + int length = keystore_get(key, strlen(key), &value); if (length != -1 && (bio = BIO_new(BIO_s_mem())) != NULL) { BIO_write(bio, value, length); } + free(value); return bio; } #endif |