Skip to content

Commit

Permalink
Android: update wolfcryptjni-ndk-gradle, wolfCrypt JNI to v1.3.0-stab…
Browse files Browse the repository at this point in the history
…le, wolfSSL to v5.3.0-stable
  • Loading branch information
cconlon committed May 23, 2022
1 parent be12343 commit b09a5b8
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 13 deletions.
23 changes: 16 additions & 7 deletions android/wolfcryptjni-ndk-gradle/app/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,20 @@
# Sets the minimum version of CMake required to build the native library.

cmake_minimum_required(VERSION 3.4.1)
project("wolfcryptjni-ndk-gradle")

# Add preprocessor defines to CFLAGS
add_definitions(-DNO_DSA -DNO_PSK -DNO_MD4 -DNO_HC128 -DNO_RABBIT
-DWOLFSSL_SHA512 -DWOLFSSL_SHA384 -DHAVE_AESGCM -DHAVE_HASHDRBG
-DHAVE_ECC -DWOLFSSL_KEY_GEN -DNO_PWDBASED -DUSE_FAST_MATH
-DTFM_ECC256 -DHAVE_DH -DUSE_FAST_MATH -DTFM_TIMING_RESISTANT
-DECC_TIMING_RESISTANT -DWC_RSA_BLINDING -DTFM_NO_ASM
)
# Add preprocessor defines to CFLAGS. These mirror the CFLAGS set in
# wolfssl/options.h if using './configure --enable-keygen'
add_definitions(-DUSE_FAST_MATH -DTFM_TIMING_RESISTANT -DECC_TIMING_RESISTANT
-DWC_RSA_BLINDING -DWOLFSSL_SHA224 -DWOLFSSL_SHA384
-DWOLFSSL_SHA512 -DHAVE_HKDF -DNO_DSA -DHAVE_ECC -DTFM_ECC256
-DECC_SHAMIR -DWC_RSA_PSS -DWOLFSSL_BASE64_ENCODE -DWOLFSSL_SHA3
-DHAVE_POLY1305 -DHAVE_CHACHA -DHAVE_HASHDRBG
-DHAVE_TLS_EXTENSIONS -DHAVE_SUPPORTED_CURVES -DHAVE_FFDHE_2048
-DWOLFSSL_TLS13 -DHAVE_EXTENDED_MASTER -DNO_RC4 -DNO_MD4
-DHAVE_ENCRYPT_THEN_MAC -DNO_PSK -DHAVE_DH_DEFAULT_PARAMS
-DWOLFSSL_KEY_GEN -DNO_DES3 -DGCM_TABLE_4BIT -DHAVE_AESGCM
-DTFM_NO_ASM)

# set wolfSSL JNI location as environment variable, change if needed
set(wolfcryptjni_DIR ${CMAKE_SOURCE_DIR}/../wolfcrypt-jni)
Expand Down Expand Up @@ -52,6 +58,7 @@ add_library(wolfssl SHARED
${wolfssl_DIR}/wolfcrypt/src/hash.c
${wolfssl_DIR}/wolfcrypt/src/hmac.c
${wolfssl_DIR}/wolfcrypt/src/integer.c
${wolfssl_DIR}/wolfcrypt/src/kdf.c
${wolfssl_DIR}/wolfcrypt/src/logging.c
${wolfssl_DIR}/wolfcrypt/src/md2.c
${wolfssl_DIR}/wolfcrypt/src/md4.c
Expand Down Expand Up @@ -99,6 +106,7 @@ add_library(wolfcryptjni SHARED
${wolfcryptjni_DIR}/jni/jni_ecc.c
${wolfcryptjni_DIR}/jni/jni_ed25519.c
${wolfcryptjni_DIR}/jni/jni_error.c
${wolfcryptjni_DIR}/jni/jni_feature_detect.c
${wolfcryptjni_DIR}/jni/jni_fips.c
${wolfcryptjni_DIR}/jni/jni_hmac.c
${wolfcryptjni_DIR}/jni/jni_logging.c
Expand All @@ -107,6 +115,7 @@ add_library(wolfcryptjni SHARED
${wolfcryptjni_DIR}/jni/jni_rng.c
${wolfcryptjni_DIR}/jni/jni_rsa.c
${wolfcryptjni_DIR}/jni/jni_sha.c
${wolfcryptjni_DIR}/jni/jni_wolfobject.c
)

# Include libraries needed for wolfSSL and wolfCrypt JNI libs
Expand Down
2 changes: 1 addition & 1 deletion android/wolfcryptjni-ndk-gradle/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ buildscript {
google()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.4.1'
classpath 'com.android.tools.build:gradle:7.2.0'

// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#Wed Jul 03 11:55:41 PDT 2019
#Mon May 23 14:17:29 MDT 2022
distributionBase=GRADLE_USER_HOME
distributionUrl=https\://services.gradle.org/distributions/gradle-7.3.3-bin.zip
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-5.5-all.zip
zipStoreBase=GRADLE_USER_HOME
2 changes: 1 addition & 1 deletion android/wolfcryptjni-ndk-gradle/wolfcrypt-jni
Submodule wolfcrypt-jni updated 114 files
2 changes: 1 addition & 1 deletion android/wolfcryptjni-ndk-gradle/wolfssl
Submodule wolfssl updated 1795 files

0 comments on commit b09a5b8

Please sign in to comment.