Index: head/security/sudo/Makefile =================================================================== --- head/security/sudo/Makefile (revision 392563) +++ head/security/sudo/Makefile (revision 392564) @@ -1,106 +1,104 @@ # Created by: erich@rrnet.com # $FreeBSD$ PORTNAME= sudo -DISTVERSION= 1.8.14p1 +PORTVERSION= 1.8.14p1 CATEGORIES= security MASTER_SITES= SUDO MAINTAINER= garga@FreeBSD.org COMMENT= Allow others to run commands as root LICENSE= sudo LICENSE_NAME= Sudo license LICENSE_FILE= ${WRKSRC}/doc/LICENSE LICENSE_PERMS= dist-mirror dist-sell pkg-mirror pkg-sell auto-accept USES= cpe libtool CPE_VENDOR= todd_miller USE_LDCONFIG= yes GNU_CONFIGURE= yes LDFLAGS+= -lgcc LDFLAGS+= -lssp_nonshared CONFIGURE_ARGS= --sysconfdir=${PREFIX}/etc \ --with-ignore-dot \ --with-tty-tickets \ --with-env-editor \ --with-logincap \ --with-long-otp-prompt OPTIONS_DEFINE= LDAP INSULTS DISABLE_ROOT_SUDO DISABLE_AUTH NOARGS_SHELL \ AUDIT OPIE NLS SSSD DOCS OPTIONS_DEFAULT= AUDIT OPTIONS_SUB= yes INSULTS_DESC= Enable insults on failures DISABLE_ROOT_SUDO_DESC= Do not allow root to run sudo DISABLE_AUTH_DESC= Do not require authentication by default NOARGS_SHELL_DESC= Run a shell if no arguments are given AUDIT_DESC= Enable BSM audit support OPIE_DESC= Enable one-time passwords (no PAM support) SSSD_DESC= Enable SSSD backend support. LOGFAC?= authpriv CONFIGURE_ARGS+= --with-logfac=${LOGFAC} # This is intentionally not an option. # SUDO_SECURE_PATH is a PATH string that will override the user's PATH. # ex: make SUDO_SECURE_PATH="/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin" .if defined(SUDO_SECURE_PATH) CONFIGURE_ARGS+= --with-secure-path="${SUDO_SECURE_PATH}" .endif NLS_USES= gettext NLS_CONFIGURE_ENABLE= nls NLS_LDFLAGS= -L${LOCALBASE}/lib -lintl NLS_CFLAGS= -I${LOCALBASE}/include INSULTS_CONFIGURE_ON= --with-insults INSULTS_CONFIGURE_ON+= --with-all-insults LDAP_USE= OPENLDAP=yes LDAP_CONFIGURE_ON= --with-ldap=${PREFIX} SUDO_LDAP_CONF?= ldap.conf LDAP_CONFIGURE_ON+= --with-ldap-conf-file=${PREFIX}/etc/${SUDO_LDAP_CONF} DISABLE_ROOT_SUDO_CONFIGURE_ON= --disable-root-sudo DISABLE_AUTH_CONFIGURE_ON= --disable-authentication NOARGS_SHELL_CONFIGURE_ENABLE= noargs-shell AUDIT_CONFIGURE_WITH= bsm-audit OPIE_CONFIGURE_ON= --with-opie OPIE_CONFIGURE_OFF= --with-pam SSSD_CONFIGURE_ON= --with-sssd SSSD_RUN_DEPENDS= sssd:${PORTSDIR}/security/sssd .include .if ${ARCH} == "arm" CONFIGURE_ARGS+= --disable-pie .endif post-patch: @${REINPLACE_CMD} -E '/install-(binaries|noexec):/,/^$$/ \ s/\$$\(INSTALL\)/& ${STRIP}/;s/-b\~/-b ~/' \ ${WRKSRC}/src/Makefile.in @${REINPLACE_CMD} -e 's,$$(srcdir)/sudoers2ldif $$(DESTDIR)$$(docdir),$$(srcdir)/sudoers2ldif $$(DESTDIR)$$(bindir),' \ ${WRKSRC}/plugins/sudoers/Makefile.in -.if empty(PORT_OPTIONS:MDOCS) @${REINPLACE_CMD} -e 's/mkinstalldirs $$(DESTDIR)$$(docdir)/mkinstalldirs/' \ -e '/for f in $$(OTHER_DOCS); do/d;/@LDAP@for f in $$(OTHER_DOCS_LDAP); do/d' \ ${WRKSRC}/doc/Makefile.in @${REINPLACE_CMD} -e 's/$$(DESTDIR)$$(sudoersdir) $$(DESTDIR)$$(docdir)/$$(DESTDIR)$$(sudoersdir)/' \ ${WRKSRC}/plugins/sudoers/Makefile.in -.endif post-install: ${INSTALL_DATA} ${FILESDIR}/pam.conf ${STAGEDIR}${PREFIX}/etc/pam.d/sudo.default ${TOUCH} ${STAGEDIR}${PREFIX}/etc/sudoers.d/.keep-me ${MV} ${STAGEDIR}${PREFIX}/etc/sudoers ${STAGEDIR}${PREFIX}/etc/sudoers.sample ${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/sudoreplay ${STRIP_CMD} ${STAGEDIR}${PREFIX}/sbin/visudo .for f in group_file.so libsudo_util.so sudoers.so system_group.so ${STRIP_CMD} ${STAGEDIR}${PREFIX}/libexec/sudo/${f} .endfor .include Index: head/security/sudo/files/patch-install-sh =================================================================== --- head/security/sudo/files/patch-install-sh (revision 392563) +++ head/security/sudo/files/patch-install-sh (revision 392564) @@ -1,28 +1,28 @@ ---- install-sh.orig 2014-09-24 01:40:15.000000000 +0900 -+++ install-sh 2014-10-10 07:26:54.000000000 +0900 -@@ -171,12 +171,6 @@ +--- install-sh.orig 2015-07-15 18:38:05 UTC ++++ install-sh +@@ -171,12 +171,6 @@ if ${DIRMODE} ; then if [ ! -d "${DEST}" ] ; then ${MKDIR} "${DEST}" || exit 1 fi - if ${CHOWNIT} ; then - ${CHOWN} "${OWNER}" "${DEST}" || exit 1 - fi - if ${CHGROUPIT} ; then - ${CHGRP} "${GROUP}" "${DEST}" || exit 1 - fi if ${CHMODIT} ; then ${CHMOD} "${MODE}" "${DEST}" || exit 1 fi -@@ -227,12 +221,6 @@ +@@ -227,12 +221,6 @@ fi if ${STRIPIT} ; then ${STRIP} "${DEST}" || exit 1 fi -if ${CHOWNIT} ; then - ${CHOWN} "${OWNER}" "${DEST}" || exit 1 -fi -if ${CHGROUPIT} ; then - ${CHGRP} "${GROUP}" "${DEST}" || exit 1 -fi if ${CHMODIT} ; then ${CHMOD} "${MODE}" "${DEST}" || exit 1 fi Index: head/security/sudo/files/patch-plugins__sudoers__Makefile.in =================================================================== --- head/security/sudo/files/patch-plugins__sudoers__Makefile.in (revision 392563) +++ head/security/sudo/files/patch-plugins__sudoers__Makefile.in (revision 392564) @@ -1,12 +1,12 @@ ---- plugins/sudoers/Makefile.in.orig 2014-10-08 05:26:20.000000000 +0900 -+++ plugins/sudoers/Makefile.in 2014-10-10 07:23:21.000000000 +0900 -@@ -323,8 +323,7 @@ +--- plugins/sudoers/Makefile.in.orig 2015-07-15 18:44:07 UTC ++++ plugins/sudoers/Makefile.in +@@ -336,8 +336,7 @@ install-plugin: sudoers.la install-dirs install-sudoers: install-dirs $(INSTALL) -d $(INSTALL_OWNER) -m 0750 $(DESTDIR)$(sudoersdir)/sudoers.d - test -r $(DESTDIR)$(sudoersdir)/sudoers || \ - $(INSTALL) $(INSTALL_OWNER) -m $(sudoers_mode) sudoers $(DESTDIR)$(sudoersdir)/sudoers + $(INSTALL) $(INSTALL_OWNER) -m $(sudoers_mode) sudoers $(DESTDIR)$(sudoersdir)/sudoers uninstall: - -$(LIBTOOL) --mode=uninstall rm -f $(DESTDIR)$(plugindir)/sudoers.la + -$(LIBTOOL) $(LTFLAGS) --mode=uninstall rm -f $(DESTDIR)$(plugindir)/sudoers.la Index: head/security/sudo/files/patch-plugins__sudoers__audit.c =================================================================== --- head/security/sudo/files/patch-plugins__sudoers__audit.c (revision 392563) +++ head/security/sudo/files/patch-plugins__sudoers__audit.c (revision 392564) @@ -1,10 +1,10 @@ ---- plugins/sudoers/audit.c.orig 2014-09-24 01:40:15.000000000 +0900 -+++ plugins/sudoers/audit.c 2014-10-10 07:24:43.000000000 +0900 -@@ -42,6 +42,7 @@ +--- plugins/sudoers/audit.c.orig 2015-07-15 18:44:07 UTC ++++ plugins/sudoers/audit.c +@@ -24,6 +24,7 @@ #ifdef HAVE_BSM_AUDIT # include "bsm_audit.h" +# include "sudo_gettext.h" #endif #ifdef HAVE_LINUX_AUDIT # include "linux_audit.h" Index: head/security/sudo/files/patch-plugins__sudoers__sudoers.in =================================================================== --- head/security/sudo/files/patch-plugins__sudoers__sudoers.in (revision 392563) +++ head/security/sudo/files/patch-plugins__sudoers__sudoers.in (revision 392564) @@ -1,17 +1,17 @@ ---- ./plugins/sudoers/sudoers.in.orig 2010-08-18 07:45:38.000000000 -0400 -+++ ./plugins/sudoers/sudoers.in 2011-04-11 12:47:45.440272893 -0400 -@@ -31,6 +31,14 @@ +--- plugins/sudoers/sudoers.in.orig 2015-07-15 18:44:07 UTC ++++ plugins/sudoers/sudoers.in +@@ -32,6 +32,14 @@ ## ## Defaults specification ## +## Uncomment if needed to preserve environmental variables related to the +## FreeBSD pkg_* utilities and fetch. +# Defaults env_keep += "PKG_PATH PKG_DBDIR PKG_TMPDIR TMPDIR PACKAGEROOT PACKAGESITE PKGDIR FTP_PASSIVE_MODE" +## +## Additionally uncomment if needed to preserve environmental variables +## related to portupgrade +# Defaults env_keep += "PORTSDIR PORTS_INDEX PORTS_DBDIR PACKAGES PKGTOOLS_CONF" +## ## You may wish to keep some of the following environment variables ## when running commands via sudo. ##