ntp: upgrade 4.2.8p15 -> 4.2.8p16

0001-libntp-Do-not-use-PTHREAD_STACK_MIN-on-glibc.patch
0001-test-Fix-build-with-new-compiler-defaults-to-fno-com.patch
refreshed for new version.

Changelog
=========
- fixes 4 vulnerabilities (3 LOW and 1 None severity),
- fixes 46 bugs
- includes 15 general improvements
- adds support for OpenSSL-3.0

Signed-off-by: Wang Mingyu <wangmy@fujitsu.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
This commit is contained in:
Wang Mingyu
2023-06-05 15:52:53 +08:00
committed by Khem Raj
parent 036ccc767a
commit d17e287c81
4 changed files with 31 additions and 29 deletions

View File

@@ -10,23 +10,24 @@ or 64Kb set by ntp should be good in glibc these days.
Upstream-Status: Pending
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Wang Mingyu <wangmy@fujitsu.com>
---
libntp/work_thread.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libntp/work_thread.c b/libntp/work_thread.c
index 03a5647..3ddd751 100644
index c1fe5c2..21db4a0 100644
--- a/libntp/work_thread.c
+++ b/libntp/work_thread.c
@@ -41,7 +41,7 @@
#ifndef THREAD_MINSTACKSIZE
# define THREAD_MINSTACKSIZE (64U * 1024)
#endif
-#ifndef __sun
+#if !defined(__sun) && !defined(__GLIBC__)
#if defined(PTHREAD_STACK_MIN) && THREAD_MINSTACKSIZE < PTHREAD_STACK_MIN
# undef THREAD_MINSTACKSIZE
# define THREAD_MINSTACKSIZE PTHREAD_STACK_MIN
@@ -598,7 +598,7 @@ start_blocking_thread_internal(
/* now clamp on lower stack limit. */
if (nstacksize < THREAD_MINSTACKSIZE)
nstacksize = THREAD_MINSTACKSIZE;
-# ifdef PTHREAD_STACK_MIN
+# ifdef PTHREAD_STACK_MIN && !defined(__GLIBC__)
if (nstacksize < PTHREAD_STACK_MIN)
nstacksize = PTHREAD_STACK_MIN;
# endif
--
2.32.0
2.34.1

View File

@@ -5,12 +5,12 @@ Subject: [PATCH] test: Fix build with new compiler defaults to -fno-common
Upstream-Status: Pending
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Wang Mingyu <wangmy@fujitsu.com>
---
sntp/tests/run-packetHandling.c | 2 +-
sntp/tests/run-t-log.c | 2 +-
sntp/tests/run-utilities.c | 2 +-
tests/libntp/test-libntp.h | 2 +-
4 files changed, 4 insertions(+), 4 deletions(-)
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/sntp/tests/run-packetHandling.c b/sntp/tests/run-packetHandling.c
index 7790b20..c58380c 100644
@@ -51,16 +51,6 @@ index f717882..98d9bf1 100644
//=======MAIN=====
diff --git a/tests/libntp/test-libntp.h b/tests/libntp/test-libntp.h
index 93050b3..60461d8 100644
--- a/tests/libntp/test-libntp.h
+++ b/tests/libntp/test-libntp.h
@@ -5,4 +5,4 @@
time_t timefunc(time_t *ptr);
void settime(int y, int m, int d, int H, int M, int S);
-time_t nowtime;
+extern time_t nowtime;
--
2.32.0
2.34.1

View File

@@ -1,9 +1,17 @@
--- ntp-4.2.8p12.original/sntp/libopts/m4/libopts.m4 2018-11-12 17:54:57.747220846 +1300
+++ ntp-4.2.8p12/sntp/libopts/m4/libopts.m4 2018-11-12 18:00:50.626211641 +1300
@@ -114,12 +114,6 @@
reproducibility fixed path to posixshell
---
sntp/libopts/m4/libopts.m4 | 7 -------
1 file changed, 7 deletions(-)
diff --git a/sntp/libopts/m4/libopts.m4 b/sntp/libopts/m4/libopts.m4
index 23738ca..4e18187 100644
--- a/sntp/libopts/m4/libopts.m4
+++ b/sntp/libopts/m4/libopts.m4
@@ -107,13 +107,6 @@ AC_DEFUN([INVOKE_LIBOPTS_MACROS_FIRST],[
AC_PROG_SED
[while :
do
- test -x "$POSIX_SHELL" && break
- POSIX_SHELL=`which bash`
- test -x "$POSIX_SHELL" && break
- POSIX_SHELL=`which dash`
@@ -13,3 +21,6 @@
POSIX_SHELL=`/bin/sh -c '
exec 2>/dev/null
if ! true ; then exit 1 ; fi
--
2.34.1

View File

@@ -6,7 +6,7 @@ or satellite receiver or modem."
HOMEPAGE = "http://support.ntp.org"
SECTION = "net"
LICENSE = "NTP"
LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=4190b39435611e92a4da74e682623f19"
LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=3a8ffebbcad335abf2c39fec38671eec"
DEPENDS = "libevent"
@@ -24,7 +24,7 @@ SRC_URI = "http://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/ntp-4.2/ntp-${PV}.tar.g
file://ntpd.list \
"
SRC_URI[sha256sum] = "f65840deab68614d5d7ceb2d0bb9304ff70dcdedd09abb79754a87536b849c19"
SRC_URI[sha256sum] = "5225858bfd843b080fb9daa5b7370519130e5e49ac3eb0371e334bdc06c52dd7"
# CVE-2016-9312 is only for windows.
# CVE-2019-11331 is inherent to RFC 5905 and cannot be fixed without breaking compatibility