This file is indexed.

/etc/init.d/courier-mta is in courier-mta 0.73.1-1.6.

This file is owned by root:root, with mode 0o755.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
#! /bin/sh -e
### BEGIN INIT INFO
# Short-Description: Courier SMTP server
# Provides:          courier-mta
# Required-Start:    $remote_fs $syslog
# Required-Stop:     $remote_fs $syslog
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
### END INIT INFO

# include init functions
. /lib/lsb/init-functions

prefix="/usr"
exec_prefix=${prefix}
sysconfdir="/etc/courier"
sbindir="${exec_prefix}/sbin"
libexecdir="${prefix}/lib/courier"
DAEMON=${sbindir}/esmtpd

test -f $DAEMON || exit 0
test -f "$sysconfdir/esmtpd" || exit 0
test -f "$sysconfdir/esmtpd-msa" || exit 0

# Check if SMTP server should be started
. ${sysconfdir}/esmtpd
START_MTA=no
case "$ESMTPDSTART" in
	[yY]*)START_MTA=yes;;
esac

START_MSA=no
. ${sysconfdir}/esmtpd-msa
case "$ESMTPDSTART" in
	[yY]*)START_MSA=yes;;
esac

if [ "$START_MTA" = "no" ] && [ $START_MSA = "no" ]; then
	exit 0
fi

case "$1" in
start)
	cd /
	
	# ensure proper permissions on /var/run/courier
	chgrp daemon /var/run/courier
	chmod g+rwx /var/run/courier

	echo -n "Starting Courier mail server:"
	${sbindir}/courier start
	echo " done."

	echo -n "Starting Courier mail filter:"
    ${sbindir}/courierfilter start
    echo " done."

	if [ "$START_MTA" = "yes" ]; then
		echo -n "Starting Courier SMTP server:"
		${sbindir}/esmtpd start
		echo " done."
	fi

	if [ "$START_MSA" = "yes" ]; then
		echo -n "Starting Courier SMTP MSA server:"
		${sbindir}/esmtpd-msa start
		echo " done."
	fi
	;;
stop)
	cd /

	if [ "$START_MSA" = "yes" ]; then
		echo -n "Stopping Courier SMTP MSA server:"
		${sbindir}/esmtpd-msa stop
		echo " done."
	fi

	if [ "$START_MTA" = "yes" ]; then
		echo -n "Stopping Courier SMTP server:"
		${sbindir}/esmtpd stop
		echo " done."
	fi

	echo -n "Stopping Courier mail filter:"
	${sbindir}/courierfilter stop
    echo " done."

	echo -n "Stopping Courier mail server:"
	${sbindir}/courier stop
	echo " done."
	;;
force-reload)
	cd /

	if [ "$START_MSA" = "yes" ]; then
		echo -n "Restarting Courier SMTP MSA server:"
		${sbindir}/esmtpd-msa restart
		echo " done."
	fi

	if [ "$START_MTA" = "yes" ]; then
		echo -n "Restarting Courier SMTP server:"
		${sbindir}/esmtpd restart
		echo " done."
	fi

	echo -n "Restarting Courier mail filter:"
	${sbindir}/courierfilter restart
    echo " done."

	echo -n "Restarting Courier mail server:"
	${sbindir}/courier restart
	echo " done."
    ;;
restart)
	$0 stop
	$0 start
	;;
*)
	echo "Usage: $0 {start|stop|restart|force-reload}" >&2
	exit 1
	;;
esac
exit 0