Date: Tuesday, February 5, 2019 @ 14:20:45 Author: archange Revision: 429630
upgpkg: tpm2-tss 2.2.0-1 Deleted: tpm2-tss/trunk/tpm2-tss-1234.patch ---------------------+ tpm2-tss-1234.patch | 153 -------------------------------------------------- 1 file changed, 153 deletions(-) Deleted: tpm2-tss-1234.patch =================================================================== --- tpm2-tss-1234.patch 2019-02-05 14:19:59 UTC (rev 429629) +++ tpm2-tss-1234.patch 2019-02-05 14:20:45 UTC (rev 429630) @@ -1,153 +0,0 @@ -From a8403c1de03ab41fd262c65e6b37e6ab430f1b42 Mon Sep 17 00:00:00 2001 -From: Jonas Witschel <[email protected]> -Date: Thu, 27 Dec 2018 23:31:41 +0100 -Subject: [PATCH 1/3] test: restrict netstat listing to IPv4 - -netstat shows both IPv4 and IPv6 bindings for tpm_server, but the -tests only connect to the simulator using IPv4. If binding to the -desired port only works for the IPv6 interface, we need to retry -with a different port instead of erroneously proceeding with the -test. - -Fixes #1227. - -Signed-off-by: Jonas Witschel <[email protected]> ---- - script/int-log-compiler.sh | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/script/int-log-compiler.sh b/script/int-log-compiler.sh -index 4077fd41..0e964b77 100755 ---- a/script/int-log-compiler.sh -+++ b/script/int-log-compiler.sh -@@ -202,9 +202,9 @@ for i in $(seq ${BACKOFF_MAX}); do - fi - PID=$(cat ${SIM_PID_FILE}) - echo "simulator PID: ${PID}"; -- netstat -ltpn 2> /dev/null | grep "${PID}" | grep -q "${SIM_PORT_DATA}" -+ netstat -lt4pn 2> /dev/null | grep "${PID}" | grep -q "${SIM_PORT_DATA}" - ret_data=$? -- netstat -ltpn 2> /dev/null | grep "${PID}" | grep -q "${SIM_PORT_CMD}" -+ netstat -lt4pn 2> /dev/null | grep "${PID}" | grep -q "${SIM_PORT_CMD}" - ret_cmd=$? - if [ \( $ret_data -eq 0 \) -a \( $ret_cmd -eq 0 \) ]; then - echo "Simulator with PID ${PID} bound to port ${SIM_PORT_DATA} and " \ - -From 5914160819e065fed2998ba38dcb990105ea8b2c Mon Sep 17 00:00:00 2001 -From: Jonas Witschel <[email protected]> -Date: Thu, 27 Dec 2018 23:53:21 +0100 -Subject: [PATCH 2/3] test: replace netstat by ss - -netstat is deprecated in favour of ss, see the netstat man page. - -Signed-off-by: Jonas Witschel <[email protected]> ---- - INSTALL.md | 4 ++-- - configure.ac | 2 +- - script/int-log-compiler.sh | 8 ++++---- - 4 files changed, 8 insertions(+), 8 deletions(-) - -diff --git a/INSTALL.md b/INSTALL.md -index 98ce298c..1cf00cef 100644 ---- a/INSTALL.md -+++ b/INSTALL.md -@@ -22,7 +22,7 @@ The following are dependencies only required when building test suites. - * OpenSSL development libraries and header files - * Unit test suite (see ./configure option --enable-unit): - * cmocka unit test framework, version >= 1.0 --* netstat executable (usually in the net-tools package) -+* ss executable (usually in the iproute2 package) - * Code coverage analysis: - * lcov - * uthash development libraries and header files -@@ -36,7 +36,7 @@ $ sudo apt -y install \ - autoconf-archive \ - libcmocka0 \ - libcmocka-dev \ -- net-tools \ -+ iproute2 \ - build-essential \ - git \ - pkg-config \ -diff --git a/configure.ac b/configure.ac -index 14b12759..54a70f97 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -167,7 +167,7 @@ AC_ARG_ENABLE([integration], - [enable_integration=no]) - AS_IF([test "x$enable_integration" = "xyes"], - [ERROR_IF_NO_PROG([tpm_server]) -- ERROR_IF_NO_PROG([netstat]) -+ ERROR_IF_NO_PROG([ss]) - ERROR_IF_NO_PROG([ps]) - ERROR_IF_NO_PROG([echo]) - ERROR_IF_NO_PROG([kill]) -diff --git a/script/int-log-compiler.sh b/script/int-log-compiler.sh -index 0e964b77..a471308e 100755 ---- a/script/int-log-compiler.sh -+++ b/script/int-log-compiler.sh -@@ -71,8 +71,8 @@ sanity_test () - exit 1 - fi - -- if [ -z "$(which netstat)" ]; then -- echo "netstat not on PATH; exiting" -+ if [ -z "$(which ss)" ]; then -+ echo "ss not on PATH; exiting" - exit 1 - fi - } -@@ -202,9 +202,9 @@ for i in $(seq ${BACKOFF_MAX}); do - fi - PID=$(cat ${SIM_PID_FILE}) - echo "simulator PID: ${PID}"; -- netstat -lt4pn 2> /dev/null | grep "${PID}" | grep -q "${SIM_PORT_DATA}" -+ ss -lt4pn 2> /dev/null | grep "${PID}" | grep -q "${SIM_PORT_DATA}" - ret_data=$? -- netstat -lt4pn 2> /dev/null | grep "${PID}" | grep -q "${SIM_PORT_CMD}" -+ ss -lt4pn 2> /dev/null | grep "${PID}" | grep -q "${SIM_PORT_CMD}" - ret_cmd=$? - if [ \( $ret_data -eq 0 \) -a \( $ret_cmd -eq 0 \) ]; then - echo "Simulator with PID ${PID} bound to port ${SIM_PORT_DATA} and " \ - -From 2d1f3acbf16e1d1b2d0e25dfbf6773d5baf31577 Mon Sep 17 00:00:00 2001 -From: Jonas Witschel <[email protected]> -Date: Thu, 27 Dec 2018 23:55:55 +0100 -Subject: [PATCH 3/3] test: use stdbuf to disable buffering of daemon log - output - -If the daemon is killed before the buffer is flushed, the log file -can be incomplete. - -Signed-off-by: Jonas Witschel <[email protected]> ---- - configure.ac | 2 +- - script/int-log-compiler.sh | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) - -diff --git a/configure.ac b/configure.ac -index 54a70f97..c0e3917e 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -171,7 +171,7 @@ AS_IF([test "x$enable_integration" = "xyes"], - ERROR_IF_NO_PROG([ps]) - ERROR_IF_NO_PROG([echo]) - ERROR_IF_NO_PROG([kill]) -- ERROR_IF_NO_PROG([nohup]) -+ ERROR_IF_NO_PROG([stdbuf]) - ERROR_IF_NO_PROG([sleep]) - ERROR_IF_NO_PROG([cat]) - ERROR_IF_NO_PROG([realpath]) -diff --git a/script/int-log-compiler.sh b/script/int-log-compiler.sh -index a471308e..badcb8f9 100755 ---- a/script/int-log-compiler.sh -+++ b/script/int-log-compiler.sh -@@ -102,7 +102,7 @@ daemon_start () - local daemon_pid_file="$4" - local daemon_env="$5" - -- env ${daemon_env} nohup ${daemon_bin} ${daemon_opts} > ${daemon_log_file} 2>&1 & -+ env ${daemon_env} stdbuf -o0 -e0 ${daemon_bin} ${daemon_opts} > ${daemon_log_file} 2>&1 & - local ret=$? - local pid=$! - if [ ${ret} -ne 0 ]; then
