aboutsummaryrefslogtreecommitdiffstats
path: root/security/sudo
diff options
context:
space:
mode:
authorpav <pav@FreeBSD.org>2005-12-18 06:12:41 +0800
committerpav <pav@FreeBSD.org>2005-12-18 06:12:41 +0800
commite8cdd888d5beed51b95866c7e5477c2ec9b8e565 (patch)
tree11ab5369ff78e18b6aaddcf531762eaeda420c37 /security/sudo
parentd663fc26aa4d78b42f8fdc17e86a4513bc54b2b5 (diff)
downloadfreebsd-ports-gnome-e8cdd888d5beed51b95866c7e5477c2ec9b8e565.tar.gz
freebsd-ports-gnome-e8cdd888d5beed51b95866c7e5477c2ec9b8e565.tar.zst
freebsd-ports-gnome-e8cdd888d5beed51b95866c7e5477c2ec9b8e565.zip
- Remove etc/sudoers on deinstall if user haven't modified it
PR: ports/69288 (based on) Approved by: maintainer timeout (mharo; year and a half)
Diffstat (limited to 'security/sudo')
-rw-r--r--security/sudo/Makefile2
-rw-r--r--security/sudo/pkg-install2
-rw-r--r--security/sudo/pkg-plist3
3 files changed, 5 insertions, 2 deletions
diff --git a/security/sudo/Makefile b/security/sudo/Makefile
index 7b6418f4393f..6fb85944b27f 100644
--- a/security/sudo/Makefile
+++ b/security/sudo/Makefile
@@ -7,6 +7,7 @@
PORTNAME= sudo
PORTVERSION= 1.6.8.12
+PORTREVISION= 1
CATEGORIES= security
MASTER_SITES= http://www.sudo.ws/sudo/dist/ \
http://probsd.org/sudoftp/ \
@@ -56,6 +57,7 @@ post-patch:
post-install:
${INSTALL_DATA} ${WRKSRC}/sample.sudoers ${PREFIX}/etc/sudoers.sample
+ ${INSTALL_DATA} ${WRKSRC}/sudoers ${PREFIX}/etc/sudoers.default
${RM} ${PREFIX}/libexec/sudo_noexec.la
.include <bsd.port.post.mk>
diff --git a/security/sudo/pkg-install b/security/sudo/pkg-install
index bd38791d206e..8848ddc2e5a0 100644
--- a/security/sudo/pkg-install
+++ b/security/sudo/pkg-install
@@ -5,6 +5,6 @@ fi
if [ -e ${PKG_PREFIX}/etc/sudoers ]; then
echo "Will not overwrite existing ${PKG_PREFIX}/etc/sudoers file."
else
- cp -p ${PKG_PREFIX}/etc/sudoers.sample ${PKG_PREFIX}/etc/sudoers
+ cp -p ${PKG_PREFIX}/etc/sudoers.default ${PKG_PREFIX}/etc/sudoers
chmod 440 ${PKG_PREFIX}/etc/sudoers
fi
diff --git a/security/sudo/pkg-plist b/security/sudo/pkg-plist
index aac447565035..97a00ff23990 100644
--- a/security/sudo/pkg-plist
+++ b/security/sudo/pkg-plist
@@ -1,6 +1,7 @@
-@unexec if cmp -s %D/etc/sudoers %D/etc/sudoers.sample; then rm -f %D/etc/sudoers; fi
+@unexec if cmp -s %D/etc/sudoers %D/etc/sudoers.default; then rm -f %D/etc/sudoers; fi
bin/sudo
bin/sudoedit
+etc/sudoers.default
etc/sudoers.sample
libexec/sudo_noexec.so
sbin/visudo