This file is indexed.

postinst is in heimdal-servers 1.6~git20131207+dfsg-1ubuntu1.

This file is a maintainer script. It is executed when installing (*inst) or removing (*rm) the package.

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
#!/bin/sh -e

add_servers() {
kshell_entry="kshell	stream	tcp	nowait	root	/usr/sbin/tcpd /usr/lib/heimdal-servers/rshd -k"
   ftp_entry="ftp	stream	tcp	nowait	root	/usr/sbin/tcpd /usr/lib/heimdal-servers/ftpd -a plain"
telnet_entry="telnet	stream	tcp	nowait	root	/usr/sbin/tcpd /usr/lib/heimdal-servers/telnetd -a none"
 pop3_entry="pop-3	stream	tcp	nowait	root	/usr/sbin/tcpd /usr/lib/heimdal-servers/popper"

	update-inetd --group KRB5 --add "$kshell_entry"
	update-inetd --group KRB5 --add "$ftp_entry"
	update-inetd --group KRB5 --add "$telnet_entry"
	update-inetd --group KRB5 --add "$pop3_entry"
}

enable_servers() {
	update-inetd --pattern '[ \t]/usr/lib/heimdal-servers/rshd' --enable kshell
	update-inetd --pattern '[ \t]/usr/lib/heimdal-servers/ftpd' --enable ftp
	update-inetd --pattern '[ \t]/usr/lib/heimdal-servers/telnetd' --enable telnet
	update-inetd --pattern '[ \t]/usr/lib/heimdal-servers/popper' --enable pop-3
}

remove_servers() {
	update-inetd --remove 'kshell[ \t].*[ \t]/usr/lib/heimdal-servers/rshd'
	update-inetd --remove 'ftp[ \t].*[ \t]/usr/lib/heimdal-servers/ftpd'
	update-inetd --remove 'telnet[ \t].*[ \t]/usr/lib/heimdal-servers/telnetd'
	update-inetd --remove 'pop-3[ \t].*[ \t]/usr/lib/heimdal-servers/popper'
}

case "$1" in
abort-upgrade | abort-deconfigure | abort-remove)
	enable_servers
	;;
configure)
	if [ -n "$2" ] && dpkg --compare-versions "$2" ge 0.3e-4; then
		enable_servers
	else
		remove_servers
		add_servers
	fi
	;;
*)
	printf "$0: incorrect arguments: $*\n" >&2
	exit 1
	;;
esac