summaryrefslogtreecommitdiff
path: root/src/main.c
diff options
context:
space:
mode:
authorWichert Akkerman <wakkerma@debian.org>1999-12-07 02:32:22 +0100
committerAndreas Beckmann <debian@abeckmann.de>2012-10-01 19:58:39 +0200
commit4e2c4cdcd62c4ab1d5e884e8afaa0bbe1b981e42 (patch)
tree3735b995048d3eccbfa7e5095e00d483c2549225 /src/main.c
parent7b9056b97dd10ee7b6b02f88a239f9f99cfa38f8 (diff)
downloadsendmail-4e2c4cdcd62c4ab1d5e884e8afaa0bbe1b981e42.tar.gz
Imported Debian patch 8.9.3-3slink1debian/8.9.3-3slink1
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/main.c b/src/main.c
index cea9d15..d1c7186 100644
--- a/src/main.c
+++ b/src/main.c
@@ -984,6 +984,18 @@ main(argc, argv, envp)
usrerr("Permission denied");
finis(FALSE, EX_USAGE);
}
+ if (OpMode == MD_INITALIAS &&
+ RealUid != 0 &&
+ RealUid != TrustedUid &&
+ !wordinclass(RealUserName, 't'))
+ {
+ if (LogLevel > 1)
+ sm_syslog(LOG_ALERT, NOQID,
+ "user %d attempted to rebuild the alias map",
+ RealUid);
+ usrerr("Permission denied");
+ finis(FALSE, EX_USAGE);
+ }
if (MeToo)
BlankEnvelope.e_flags |= EF_METOO;