Tests: ESAPI: Add 8 Tests

Add tests for CreateLoaded, HashSequenceStart,
NV-RAM counters, NV-RAM SetBits, Object-ChangeAuth,
NV-ChangeAuth and PolicyPassword.

Signed-off-by: Andreas Fuchs <andreas.fuchs@sit.fraunhofer.de>
diff --git a/Makefile-test.am b/Makefile-test.am
index b4cebef..8107128 100644
--- a/Makefile-test.am
+++ b/Makefile-test.am
@@ -85,9 +85,13 @@
     test/tpmclient/tpmclient.int
 if ESAPI
 TESTS_INTEGRATION += \
+    test/integration/esys-clear.int \
+    test/integration/esys-clear-session.int \
     test/integration/esys-clockset.int \
     test/integration/esys-clockset-session.int \
     test/integration/esys-create-fail.int \
+    test/integration/esys-createloaded.int \
+    test/integration/esys-createloaded-session.int \
     test/integration/esys-create-password-auth.int \
     test/integration/esys-create-primary-ecc-hmac.int \
     test/integration/esys-create-primary-hmac.int \
@@ -95,13 +99,23 @@
     test/integration/esys-evict-control-serialization.int \
     test/integration/esys-get-capability.int \
     test/integration/esys-get-random.int \
+    test/integration/esys-hashsequencestart.int \
+    test/integration/esys-hashsequencestart-session.int \
+    test/integration/esys-hierarchychangeauth.int \
+    test/integration/esys-hmacsequencestart.int \
+    test/integration/esys-hmacsequencestart-session.int \
     test/integration/esys-make-credential.int \
     test/integration/esys-make-credential-session.int \
+    test/integration/esys-nv-ram-counter.int \
+    test/integration/esys-nv-ram-counter-session.int \
     test/integration/esys-nv-ram-extend-index.int \
     test/integration/esys-nv-ram-extend-index-session.int \
-    test/integration/esys-nv-ram-ordinary-index.int \
-    test/integration/esys-nv-ram-ordinary-index-session.int \
+    test/integration/esys-nv-ram-set-bits.int \
+    test/integration/esys-nv-ram-set-bits-session.int \
     test/integration/esys-quote.int \
+    test/integration/esys-object-changeauth.int \
+    test/integration/esys-policy-nv-changeauth.int \
+    test/integration/esys-policy-password.int \
     test/integration/esys-rsa-encrypt-decrypt.int \
     test/integration/esys-save-and-load-context.int
 endif #ESAPI
@@ -287,6 +301,24 @@
     test/integration/system-api.int.c
 
 if ESAPI
+test_integration_esys_clear_int_CFLAGS  = $(AM_CFLAGS) \
+    -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
+    -I$(srcdir)/esapi/esapi_util
+test_integration_esys_clear_int_LDADD   = $(TESTS_LDADD)
+test_integration_esys_clear_int_LDFLAGS = $(TESTS_LDFLAGS) -lgcrypt
+test_integration_esys_clear_int_SOURCES = \
+    test/integration/esys-clear.int.c \
+    test/integration/main-esapi.c test/integration/test-esapi.h
+
+test_integration_esys_clear_session_int_CFLAGS  = $(AM_CFLAGS) \
+    -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
+    -I$(srcdir)/esapi/esapi_util -DTEST_SESSION
+test_integration_esys_clear_session_int_LDADD   = $(TESTS_LDADD)
+test_integration_esys_clear_session_int_LDFLAGS = $(TESTS_LDFLAGS) -lgcrypt
+test_integration_esys_clear_session_int_SOURCES = \
+    test/integration/esys-clear.int.c \
+    test/integration/main-esapi.c test/integration/test-esapi.h
+
 test_integration_esys_clockset_int_CFLAGS  = $(AM_CFLAGS) \
     -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
     -I$(srcdir)/esapi/esapi_util
@@ -314,6 +346,24 @@
     test/integration/esys-create-fail.int.c \
     test/integration/main-esapi.c test/integration/test-esapi.h
 
+test_integration_esys_createloaded_int_CFLAGS  = $(AM_CFLAGS) \
+    -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
+    -I$(srcdir)/esapi/esapi_util
+test_integration_esys_createloaded_int_LDADD   = $(TESTS_LDADD)
+test_integration_esys_createloaded_int_LDFLAGS = $(TESTS_LDFLAGS) -lgcrypt
+test_integration_esys_createloaded_int_SOURCES = \
+    test/integration/esys-createloaded.int.c \
+    test/integration/main-esapi.c test/integration/test-esapi.h
+
+test_integration_esys_createloaded_session_int_CFLAGS  = $(AM_CFLAGS) \
+    -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
+    -I$(srcdir)/esapi/esapi_util -DTEST_SESSION
+test_integration_esys_createloaded_session_int_LDADD   = $(TESTS_LDADD)
+test_integration_esys_createloaded_session_int_LDFLAGS = $(TESTS_LDFLAGS) -lgcrypt
+test_integration_esys_createloaded_session_int_SOURCES = \
+    test/integration/esys-createloaded.int.c \
+    test/integration/main-esapi.c test/integration/test-esapi.h
+
 test_integration_esys_create_password_auth_int_CFLAGS  = $(AM_CFLAGS) \
     -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
     -I$(srcdir)/esapi/esapi_util
@@ -377,6 +427,51 @@
     test/integration/esys-get-random.int.c \
     test/integration/main-esapi.c test/integration/test-esapi.h
 
+test_integration_esys_hashsequencestart_int_CFLAGS  = $(AM_CFLAGS) \
+    -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
+    -I$(srcdir)/esapi/esapi_util
+test_integration_esys_hashsequencestart_int_LDADD   = $(TESTS_LDADD)
+test_integration_esys_hashsequencestart_int_LDFLAGS = $(TESTS_LDFLAGS) -lgcrypt
+test_integration_esys_hashsequencestart_int_SOURCES = \
+    test/integration/esys-hashsequencestart.int.c \
+    test/integration/main-esapi.c test/integration/test-esapi.h
+
+test_integration_esys_hashsequencestart_session_int_CFLAGS  = $(AM_CFLAGS) \
+    -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
+    -I$(srcdir)/esapi/esapi_util -DTEST_SESSION
+test_integration_esys_hashsequencestart_session_int_LDADD   = $(TESTS_LDADD)
+test_integration_esys_hashsequencestart_session_int_LDFLAGS = $(TESTS_LDFLAGS) -lgcrypt
+test_integration_esys_hashsequencestart_session_int_SOURCES = \
+    test/integration/esys-hashsequencestart.int.c \
+    test/integration/main-esapi.c test/integration/test-esapi.h
+
+test_integration_esys_hmacsequencestart_int_CFLAGS  = $(AM_CFLAGS) \
+    -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
+    -I$(srcdir)/esapi/esapi_util
+test_integration_esys_hmacsequencestart_int_LDADD   = $(TESTS_LDADD)
+test_integration_esys_hmacsequencestart_int_LDFLAGS = $(TESTS_LDFLAGS) -lgcrypt
+test_integration_esys_hmacsequencestart_int_SOURCES = \
+    test/integration/esys-hmacsequencestart.int.c \
+    test/integration/main-esapi.c test/integration/test-esapi.h
+
+test_integration_esys_hmacsequencestart_session_int_CFLAGS  = $(AM_CFLAGS) \
+    -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
+    -I$(srcdir)/esapi/esapi_util -DTEST_SESSION
+test_integration_esys_hmacsequencestart_session_int_LDADD   = $(TESTS_LDADD)
+test_integration_esys_hmacsequencestart_session_int_LDFLAGS = $(TESTS_LDFLAGS) -lgcrypt
+test_integration_esys_hmacsequencestart_session_int_SOURCES = \
+    test/integration/esys-hmacsequencestart.int.c \
+    test/integration/main-esapi.c test/integration/test-esapi.h
+
+test_integration_esys_hierarchychangeauth_int_CFLAGS  = $(AM_CFLAGS) \
+    -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
+    -I$(srcdir)/esapi/esapi_util
+test_integration_esys_hierarchychangeauth_int_LDADD   = $(TESTS_LDADD)
+test_integration_esys_hierarchychangeauth_int_LDFLAGS = $(TESTS_LDFLAGS) -lgcrypt
+test_integration_esys_hierarchychangeauth_int_SOURCES = \
+    test/integration/esys-hierarchychangeauth.int.c \
+    test/integration/main-esapi.c test/integration/test-esapi.h
+
 test_integration_esys_make_credential_int_CFLAGS  = $(AM_CFLAGS) \
     -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
     -I$(srcdir)/esapi/esapi_util
@@ -395,6 +490,24 @@
     test/integration/esys-make-credential.int.c \
     test/integration/main-esapi.c test/integration/test-esapi.h
 
+test_integration_esys_nv_ram_counter_int_CFLAGS  = $(AM_CFLAGS) \
+    -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
+    -I$(srcdir)/esapi/esapi_util
+test_integration_esys_nv_ram_counter_int_LDADD   = $(TESTS_LDADD)
+test_integration_esys_nv_ram_counter_int_LDFLAGS = $(TESTS_LDFLAGS) -lgcrypt
+test_integration_esys_nv_ram_counter_int_SOURCES = \
+    test/integration/esys-nv-ram-counter.int.c \
+    test/integration/main-esapi.c test/integration/test-esapi.h
+
+test_integration_esys_nv_ram_counter_session_int_CFLAGS  = $(AM_CFLAGS) \
+    -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
+    -I$(srcdir)/esapi/esapi_util -DTEST_SESSION
+test_integration_esys_nv_ram_counter_session_int_LDADD   = $(TESTS_LDADD)
+test_integration_esys_nv_ram_counter_session_int_LDFLAGS = $(TESTS_LDFLAGS) -lgcrypt
+test_integration_esys_nv_ram_counter_session_int_SOURCES = \
+    test/integration/esys-nv-ram-counter.int.c \
+    test/integration/main-esapi.c test/integration/test-esapi.h
+
 test_integration_esys_nv_ram_extend_index_int_CFLAGS  = $(AM_CFLAGS) \
     -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
     -I$(srcdir)/esapi/esapi_util
@@ -413,22 +526,49 @@
     test/integration/esys-nv-ram-extend-index.int.c \
     test/integration/main-esapi.c test/integration/test-esapi.h
 
-test_integration_esys_nv_ram_ordinary_index_int_CFLAGS  = $(AM_CFLAGS) \
+test_integration_esys_nv_ram_set_bits_int_CFLAGS  = $(AM_CFLAGS) \
     -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
     -I$(srcdir)/esapi/esapi_util
-test_integration_esys_nv_ram_ordinary_index_int_LDADD   = $(TESTS_LDADD)
-test_integration_esys_nv_ram_ordinary_index_int_LDFLAGS = $(TESTS_LDFLAGS) -lgcrypt
-test_integration_esys_nv_ram_ordinary_index_int_SOURCES = \
-    test/integration/esys-nv-ram-ordinary-index.int.c \
+test_integration_esys_nv_ram_set_bits_int_LDADD   = $(TESTS_LDADD)
+test_integration_esys_nv_ram_set_bits_int_LDFLAGS = $(TESTS_LDFLAGS) -lgcrypt
+test_integration_esys_nv_ram_set_bits_int_SOURCES = \
+    test/integration/esys-nv-ram-set-bits.int.c \
     test/integration/main-esapi.c test/integration/test-esapi.h
 
-test_integration_esys_nv_ram_ordinary_index_session_int_CFLAGS  = $(AM_CFLAGS) \
+test_integration_esys_nv_ram_set_bits_session_int_CFLAGS  = $(AM_CFLAGS) \
     -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
     -I$(srcdir)/esapi/esapi_util -DTEST_SESSION
-test_integration_esys_nv_ram_ordinary_index_session_int_LDADD   = $(TESTS_LDADD)
-test_integration_esys_nv_ram_ordinary_index_session_int_LDFLAGS = $(TESTS_LDFLAGS) -lgcrypt
-test_integration_esys_nv_ram_ordinary_index_session_int_SOURCES = \
-    test/integration/esys-nv-ram-ordinary-index.int.c \
+test_integration_esys_nv_ram_set_bits_session_int_LDADD   = $(TESTS_LDADD)
+test_integration_esys_nv_ram_set_bits_session_int_LDFLAGS = $(TESTS_LDFLAGS) -lgcrypt
+test_integration_esys_nv_ram_set_bits_session_int_SOURCES = \
+    test/integration/esys-nv-ram-set-bits.int.c \
+    test/integration/main-esapi.c test/integration/test-esapi.h
+
+test_integration_esys_object_changeauth_int_CFLAGS  = $(AM_CFLAGS) \
+    -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
+    -I$(srcdir)/esapi/esapi_util
+test_integration_esys_object_changeauth_int_LDADD   = $(TESTS_LDADD)
+test_integration_esys_object_changeauth_int_LDFLAGS = $(TESTS_LDFLAGS) -lgcrypt
+test_integration_esys_object_changeauth_int_SOURCES = \
+    test/integration/esys-object-changeauth.int.c \
+    test/integration/main-esapi.c test/integration/test-esapi.h
+
+test_integration_esys_policy_nv_changeauth_int_CFLAGS  = $(AM_CFLAGS) \
+    -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
+    -I$(srcdir)/esapi/esapi_util
+test_integration_esys_policy_nv_changeauth_int_LDADD   = $(TESTS_LDADD)
+test_integration_esys_policy_nv_changeauth_int_LDFLAGS = $(TESTS_LDFLAGS) -lgcrypt
+test_integration_esys_policy_nv_changeauth_int_SOURCES = \
+    test/integration/esys-policy-nv-changeauth.int.c \
+    test/integration/main-esapi.c test/integration/test-esapi.h
+
+test_integration_esys_policy_password_int_CFLAGS  = $(AM_CFLAGS) \
+    -I. -I$(srcdir)/esapi/esapi -I$(srcdir)/include/esapi \
+    -I$(srcdir)/esapi/esapi_util
+test_integration_esys_policy_password_int_LDADD   = $(TESTS_LDADD)
+test_integration_esys_policy_password_int_LDFLAGS = $(TESTS_LDFLAGS) -lgcrypt
+test_integration_esys_policy_password_int_SOURCES = \
+    test/integration/esys-policy-password.int.c \
     test/integration/main-esapi.c test/integration/test-esapi.h
 
 test_integration_esys_quote_int_CFLAGS  = $(AM_CFLAGS) \