Skip to content

Commit

Permalink
Added Symmetric Encryption
Browse files Browse the repository at this point in the history
Signed-off-by: Gael Guegan <[email protected]>
  • Loading branch information
Gael Guegan committed Jul 26, 2019
1 parent 568d700 commit 33f681e
Show file tree
Hide file tree
Showing 9 changed files with 475 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ script:
else
export SCAN_PREFIX="scan-build --status-bugs"
fi
- $SCAN_PREFIX ../configure $CONFIGURE_OPTIONS --enable-unit --enable-integration
- $SCAN_PREFIX ../configure $CONFIGURE_OPTIONS --enable-unit --enable-integration --enable-symmetric
- $SCAN_PREFIX make -j$(nproc)
- make -j$(nproc) check
- cat test-suite.log config.log
Expand Down
6 changes: 4 additions & 2 deletions Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,8 @@ libtpm2tss_la_SOURCES = src/tpm2-tss-engine.c \
src/tpm2-tss-engine-err.h \
src/tpm2-tss-engine-ecc.c \
src/tpm2-tss-engine-rand.c \
src/tpm2-tss-engine-rsa.c
src/tpm2-tss-engine-rsa.c \
src/tpm2-tss-engine-ciphers.c
libtpm2tss_la_CFLAGS = $(AM_CFLAGS)
libtpm2tss_la_LIBADD = $(AM_LDADD)
libtpm2tss_la_LDFLAGS = $(AM_LDFLAGS) -no-undefined -avoid-version \
Expand Down Expand Up @@ -121,7 +122,8 @@ TESTS_SHELL = test/ecdsa.sh \
test/rsasign_persistent.sh \
test/rsasign_persistent_emptyauth.sh \
test/sserver.sh \
test/sclient.sh
test/sclient.sh \
test/ciphers.sh
EXTRA_DIST += $(TESTS_SHELL)
TEST_EXTENSIONS = .sh
SH_LOG_COMPILER = $(srcdir)/test/sh_log_compiler.sh
Expand Down
13 changes: 9 additions & 4 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ AC_CANONICAL_SYSTEM

AM_INIT_AUTOMAKE([foreign subdir-objects -Wall -Wno-portability])
#Backward compatible setting of "silent-rules"
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
AM_MAINTAINER_MODE([enable])

AC_PROG_CC
Expand All @@ -78,6 +78,12 @@ AC_ARG_ENABLE([tctienvvar],
[enable_tctienvvar=yes])
AS_IF([test "x$enable_tctienvvar" = xyes], [AC_DEFINE([ENABLE_TCTIENVVAR], [1])])

AC_ARG_ENABLE([symmetric],
[AS_HELP_STRING([--enable-symmetric],
[Enable symmetric encryption])],,
[enable_symmetric=no])
AS_IF([test "x$enable_symmetric" = xyes], [AC_DEFINE([ENABLE_SYMMETRIC], [1])])

AC_CONFIG_FILES([Makefile])

AC_ARG_ENABLE([defaultflags],
Expand Down Expand Up @@ -127,7 +133,7 @@ AC_PATH_PROG([EXPECT], [expect])
AS_IF([test -z "$EXPECT"],
[AC_MSG_WARN([Required executable expect not found, some tests might fail])])

AC_ARG_WITH([enginesdir],
AC_ARG_WITH([enginesdir],
[AS_HELP_STRING([--with-enginesdir],
[Set the OpenSSL engine directory (default: use pkg-config)])],
[],
Expand All @@ -154,7 +160,7 @@ AC_ARG_ENABLE([unit],
[AS_HELP_STRING([--enable-unit],
[build cmocka unit tests])],,
[enable_unit=no])
AS_IF([test "x$enable_unit" != "xno" ],
AS_IF([test "x$enable_unit" != "xno" ],
[PKG_CHECK_MODULES([CMOCKA], [cmocka >= 1.0])])
AM_CONDITIONAL([UNIT], [test "x$enable_unit" != xno])

Expand Down Expand Up @@ -188,4 +194,3 @@ $PACKAGE_NAME $VERSION
enginesdir: $with_enginesdir
completionsdir: $with_completionsdir
])

Loading

0 comments on commit 33f681e

Please sign in to comment.