aboutsummaryrefslogtreecommitdiff
path: root/security/sudo
diff options
context:
space:
mode:
Diffstat (limited to 'security/sudo')
-rw-r--r--security/sudo/Makefile12
-rw-r--r--security/sudo/pkg-message19
2 files changed, 30 insertions, 1 deletions
diff --git a/security/sudo/Makefile b/security/sudo/Makefile
index 6fb85944b27f..ecfa69dbfe11 100644
--- a/security/sudo/Makefile
+++ b/security/sudo/Makefile
@@ -24,7 +24,6 @@ DISTNAME= ${PORTNAME}-1.6.8p12
MAINTAINER= mharo@FreeBSD.org
COMMENT= Allow others to run commands as root
-USE_REINPLACE= yes
GNU_CONFIGURE= yes
CONFIGURE_ARGS= --sysconfdir=${PREFIX}/etc \
@@ -36,8 +35,18 @@ CONFIGURE_ARGS= --sysconfdir=${PREFIX}/etc \
--with-long-otp-prompt \
--with-pam
+OPTIONS= LDAP "With LDAP support" off \
+ OPIE "With OPIE support" off \
+ SHELL_SETS_HOME "Set $HOME to target user in shell mode" off
+
.include <bsd.port.pre.mk>
+.if defined(WITH_LDAP)
+USE_OPENLDAP=yes
+CONFIGURE_ARGS+=--with-ldap=${PREFIX}
+CONFIGURE_ARGS+=--with-ldap-conf-file=${PREFIX}/etc/ldap.conf
+.endif
+
.if defined(WITH_OPIE) || ${OSVERSION} > 500021
CONFIGURE_ARGS+=--with-opie
.else
@@ -59,5 +68,6 @@ 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
+ ${CAT} ${PKGMESSAGE}
.include <bsd.port.post.mk>
diff --git a/security/sudo/pkg-message b/security/sudo/pkg-message
new file mode 100644
index 000000000000..4d615b52f130
--- /dev/null
+++ b/security/sudo/pkg-message
@@ -0,0 +1,19 @@
+If you store accounts in external place and want to use password
+authentication for sudo, you must create /etc/pam.d/sudo file like:
+
+=====================================================================
+#
+# PAM configuration for the "sudoers" service
+#
+# auth
+auth include system
+
+# account
+account include system
+
+# session
+session include system
+
+# password
+password include system
+=====================================================================