Skip to contentSkip to conversation

policycoreutils: drop the patch for old refpolicy

PATCH Applied [email protected] 2 participants 2 messages Mar 13, 2014 – Apr 3, 2014

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 policycoreutils: drop the patch for old refpolicy

From: Jackie Huang <[email protected]>

The patch policycoreutils-revert-run_init-open_init_pty.patch is only for refpolicy version older than 2.20120725, now the refpolicy is updated to 2.20130424 so drop the patch or it will make run_init fail to start some init scripts.

---
 ...cycoreutils-revert-run_init-open_init_pty.patch |   40 --------------------
 recipes-security/selinux/policycoreutils_2.2.5.bb  |    1 -
 recipes-security/selinux/policycoreutils_git.bb    |    1 -
 3 files changed, 42 deletions(-)
 delete mode 100644 recipes-security/selinux/policycoreutils/policycoreutils-revert-run_init-open_init_pty.patch
recipes-security/selinux/policycoreutils/policycoreutils-revert-run_init-open_init_pty.patch deleted +0 -40
deleted file mode 100644
index aedae21..0000000
@@ -1,40 +0,0 @@
-From 0b2d9e47c759bf2d0842f20d6af5c4e678e9c34c Mon Sep 17 00:00:00 2001
-From: Xin Ouyang <[email protected]>
-Date: Tue, 4 Jun 2013 17:04:44 +0800
-Subject: [PATCH] policycoreutils: Revert "run_init: If open_init_pty ..."
-
-This reverts commit d46e88abb6e1f7b0228c30c98ba4fb739e63cda3.
-
-In d46e88ab, run_init will not use open_init_pty as Redhat did. Our
-old refpolicy still does no work well with this, and make init scripts
-fail to start so revert it.
-
-This patch should be dropped while refpolicy is upreved to 2.20120725+.
-
-Upstream-Status: Inappropriate [for old refpolicy]
-
----
- run_init/run_init.c | 7 -------
- 1 file changed, 7 deletions(-)
-
-diff --git a/run_init/run_init.c b/run_init/run_init.c
-index 92034be..9db766c 100644
---- a/run_init/run_init.c
-+++ b/run_init/run_init.c
-@@ -406,13 +406,6 @@ int main(int argc, char *argv[])
- 			new_context);
- 		exit(-1);
- 	}
--	if (! access("/usr/sbin/open_init_pty", X_OK)) {
--		if (execvp(argv[1], argv + 1)) {
--			perror("execvp");
--			exit(-1);
--		}
--		return 0;
--	}
- 	/*
- 	 * Do not execvp the command directly from run_init; since it would run
- 	 * under with a pty under sysadm_devpts_t. Instead, we call open_init_tty,
--- 
-1.8.1.2
-
recipes-security/selinux/policycoreutils_2.2.5.bb +0 -1
index d851f74..64cb495 100644
@@ -9,7 +9,6 @@ SRC_URI[md5sum] = "a2963d7024c5c4ce89f2459d48f91ec8"
 SRC_URI[sha256sum] = "bbf850a8c3c2f371f439d6525663eecdd3a737acd594d2f27f8d8f3a07830cc4"
 
 SRC_URI += "\
-	file://policycoreutils-revert-run_init-open_init_pty.patch \
 	file://policycoreutils-fix-sepolicy-install-path.patch \
 	file://policycoreutils-make-O_CLOEXEC-optional.patch \
 	file://policycoreutils-loadpolicy-symlink.patch \
recipes-security/selinux/policycoreutils_git.bb +0 -1
index 9a6425b..92f6c26 100644
@@ -7,7 +7,6 @@ include ${BPN}.inc
 LIC_FILES_CHKSUM = "file://COPYING;md5=393a5ca445f6965873eca0259a17f833"
 
 SRC_URI += "\
-	file://policycoreutils-revert-run_init-open_init_pty.patch \
 	file://policycoreutils-fix-sepolicy-install-path.patch \
 	file://policycoreutils-make-O_CLOEXEC-optional.patch \
 	"
Signature · 1 line
1.7.9.5
#1 lore raw

Merged, thanks.
-J.

Quoted 88 lines · [[yocto] [meta-selinux][PATCH] policycoreutils: drop the patch for old…

From: Jackie Huang <[email protected]>

The patch policycoreutils-revert-run_init-open_init_pty.patch is only for refpolicy version older than 2.20120725, now the refpolicy is updated to 2.20130424 so drop the patch or it will make run_init fail to start some init scripts.

---
 ...cycoreutils-revert-run_init-open_init_pty.patch |   40 --------------------
 recipes-security/selinux/policycoreutils_2.2.5.bb  |    1 -
 recipes-security/selinux/policycoreutils_git.bb    |    1 -
 3 files changed, 42 deletions(-)
 delete mode 100644 recipes-security/selinux/policycoreutils/policycoreutils-revert-run_init-open_init_pty.patch
recipes-security/selinux/policycoreutils/policycoreutils-revert-run_init-open_init_pty.patch deleted +0 -40
deleted file mode 100644
index aedae21..0000000
@@ -1,40 +0,0 @@
-From 0b2d9e47c759bf2d0842f20d6af5c4e678e9c34c Mon Sep 17 00:00:00 2001
-From: Xin Ouyang <[email protected]>
-Date: Tue, 4 Jun 2013 17:04:44 +0800
-Subject: [PATCH] policycoreutils: Revert "run_init: If open_init_pty ..."
-
-This reverts commit d46e88abb6e1f7b0228c30c98ba4fb739e63cda3.
-
-In d46e88ab, run_init will not use open_init_pty as Redhat did. Our
-old refpolicy still does no work well with this, and make init scripts
-fail to start so revert it.
-
-This patch should be dropped while refpolicy is upreved to 2.20120725+.
-
-Upstream-Status: Inappropriate [for old refpolicy]
-
----
- run_init/run_init.c | 7 -------
- 1 file changed, 7 deletions(-)
-
-diff --git a/run_init/run_init.c b/run_init/run_init.c
-index 92034be..9db766c 100644
---- a/run_init/run_init.c
-+++ b/run_init/run_init.c
-@@ -406,13 +406,6 @@ int main(int argc, char *argv[])
- 			new_context);
- 		exit(-1);
- 	}
--	if (! access("/usr/sbin/open_init_pty", X_OK)) {
--		if (execvp(argv[1], argv + 1)) {
--			perror("execvp");
--			exit(-1);
--		}
--		return 0;
--	}
- 	/*
- 	 * Do not execvp the command directly from run_init; since it would run
- 	 * under with a pty under sysadm_devpts_t. Instead, we call open_init_tty,
--- 
-1.8.1.2
-
recipes-security/selinux/policycoreutils_2.2.5.bb +0 -1
index d851f74..64cb495 100644
@@ -9,7 +9,6 @@ SRC_URI[md5sum] = "a2963d7024c5c4ce89f2459d48f91ec8"
 SRC_URI[sha256sum] = "bbf850a8c3c2f371f439d6525663eecdd3a737acd594d2f27f8d8f3a07830cc4"
 
 SRC_URI += "\
-	file://policycoreutils-revert-run_init-open_init_pty.patch \
 	file://policycoreutils-fix-sepolicy-install-path.patch \
 	file://policycoreutils-make-O_CLOEXEC-optional.patch \
 	file://policycoreutils-loadpolicy-symlink.patch \
recipes-security/selinux/policycoreutils_git.bb +0 -1
index 9a6425b..92f6c26 100644
@@ -7,7 +7,6 @@ include ${BPN}.inc
 LIC_FILES_CHKSUM = "file://COPYING;md5=393a5ca445f6965873eca0259a17f833"
 
 SRC_URI += "\
-	file://policycoreutils-revert-run_init-open_init_pty.patch \
 	file://policycoreutils-fix-sepolicy-install-path.patch \
 	file://policycoreutils-make-O_CLOEXEC-optional.patch \
 	"
Signature · 1 line
1.7.9.5
Signature · 2 lines
-Joe MacDonald.
:wq