You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: configure.ac
+25Lines changed: 25 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -311,6 +311,31 @@ then
311
311
then
312
312
AC_MSG_ERROR([fwTPM requires wolfCrypt. Do not use --disable-wolfcrypt with --enable-fwtpm.])
313
313
fi
314
+
# Probe wolfSSL for optional RSA features required by fwTPM's RSA key
315
+
# paths. These aren't hard errors — ECC-only fwTPM works without them —
316
+
# so emit warnings rather than failing configure.
317
+
AC_MSG_CHECKING([wolfSSL for WOLFSSL_KEY_GEN (needed for RSA CreatePrimary)])
318
+
AC_COMPILE_IFELSE([AC_LANG_SOURCE([[
319
+
#include <wolfssl/options.h>
320
+
#ifndef WOLFSSL_KEY_GEN
321
+
#error WOLFSSL_KEY_GEN not defined
322
+
#endif
323
+
int main(void){return 0;}
324
+
]])],
325
+
[AC_MSG_RESULT([yes])],
326
+
[AC_MSG_RESULT([no])
327
+
AC_MSG_WARN([fwTPM: wolfSSL lacks WOLFSSL_KEY_GEN — RSA CreatePrimary will fail at runtime. Rebuild wolfSSL with --enable-keygen or use --disable-fwtpm.])])
328
+
AC_MSG_CHECKING([wolfSSL for WC_RSA_NO_PADDING (needed for RSA_Encrypt/Decrypt)])
329
+
AC_COMPILE_IFELSE([AC_LANG_SOURCE([[
330
+
#include <wolfssl/options.h>
331
+
#ifndef WC_RSA_NO_PADDING
332
+
#error WC_RSA_NO_PADDING not defined
333
+
#endif
334
+
int main(void){return 0;}
335
+
]])],
336
+
[AC_MSG_RESULT([yes])],
337
+
[AC_MSG_RESULT([no])
338
+
AC_MSG_WARN([fwTPM: wolfSSL lacks WC_RSA_NO_PADDING — raw RSA operations will return TPM_RC_SCHEME. Rebuild wolfSSL with CFLAGS="-DWC_RSA_NO_PADDING".])])
314
339
# WOLFTPM_FWTPM is added to options.h (via OPTION_FLAGS) but NOT to AM_CFLAGS.
315
340
# It gates server-specific code in tpm2_packet.c/tpm2_param_enc.c and is set
316
341
# as a compile flag only for the fwtpm_server target in src/fwtpm/include.am.
0 commit comments