Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 7 Mar 2022 23:03:42 GMT
From:      Bryan Drewery <bdrewery@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: a12058fae3bb - main - security/openssh-portable: Again fix procctl(2) usage
Message-ID:  <202203072303.227N3gXg068025@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by bdrewery:

URL: https://cgit.FreeBSD.org/ports/commit/?id=a12058fae3bb09a1aba41d24383b6f1d93f2b330

commit a12058fae3bb09a1aba41d24383b6f1d93f2b330
Author:     Bryan Drewery <bdrewery@FreeBSD.org>
AuthorDate: 2022-03-07 22:49:28 +0000
Commit:     Bryan Drewery <bdrewery@FreeBSD.org>
CommitDate: 2022-03-07 23:02:47 +0000

    security/openssh-portable: Again fix procctl(2) usage
    
    The 8.9p1 update was supposed to have a fix for incorrect
    use of procctl(2) but was left out for some reason. A wrong
    assumption missed keeping it in ae66cffc19f357cbd5.
    
    PR:          262352
---
 security/openssh-portable/Makefile                  |  2 +-
 .../openssh-portable/files/patch-platform-tracing.c | 21 +++++++++++++++++++++
 2 files changed, 22 insertions(+), 1 deletion(-)

diff --git a/security/openssh-portable/Makefile b/security/openssh-portable/Makefile
index defef139f14e..ee88c6fca548 100644
--- a/security/openssh-portable/Makefile
+++ b/security/openssh-portable/Makefile
@@ -2,7 +2,7 @@
 
 PORTNAME=	openssh
 DISTVERSION=	8.9p1
-PORTREVISION=	1
+PORTREVISION=	2
 PORTEPOCH=	1
 CATEGORIES=	security
 MASTER_SITES=	OPENBSD/OpenSSH/portable
diff --git a/security/openssh-portable/files/patch-platform-tracing.c b/security/openssh-portable/files/patch-platform-tracing.c
new file mode 100644
index 000000000000..160def21ac3e
--- /dev/null
+++ b/security/openssh-portable/files/patch-platform-tracing.c
@@ -0,0 +1,21 @@
+--- platform-tracing.c.orig	2022-03-07 14:48:27.152541000 -0800
++++ platform-tracing.c	2022-03-07 14:56:33.402458000 -0800
+@@ -32,6 +32,9 @@
+ #include <stdarg.h>
+ #include <stdio.h>
+ #include <string.h>
++#if defined(HAVE_PROCCTL)
++#include <unistd.h>
++#endif
+ 
+ #include "log.h"
+ 
+@@ -42,7 +45,7 @@ platform_disable_tracing(int strict)
+ 	/* On FreeBSD, we should make this process untraceable */
+ 	int disable_trace = PROC_TRACE_CTL_DISABLE;
+ 
+-	if (procctl(P_PID, 0, PROC_TRACE_CTL, &disable_trace) && strict)
++	if (procctl(P_PID, getpid(), PROC_TRACE_CTL, &disable_trace) && strict)
+ 		fatal("unable to make the process untraceable: %s",
+ 		    strerror(errno));
+ #endif



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202203072303.227N3gXg068025>