1#!/bin/sh
2# setup.sh
3# This script should be run after the usermin archive is unpacked, in order
4# to setup the various config files
5
6# Find install directory
7LANG=
8export LANG
9cd `dirname $0`
10if [ -x /bin/pwd ]; then
11	wadir=`/bin/pwd`
12else
13	wadir=`pwd`;
14fi
15srcdir=$wadir
16ver=`cat "$wadir/version"`
17
18tempdir=/tmp/.usermin
19mkdir -p $tempdir
20
21echo "***********************************************************************"
22echo "*            Welcome to the Usermin setup script, version $ver       *"
23echo "***********************************************************************"
24echo "Usermin is a web-based interface that allows Unix-like operating"
25echo "systems and common Unix services to be easily administered."
26echo ""
27
28# Only root can run this
29id | grep "uid=0(" >/dev/null
30if [ $? != "0" ]; then
31	uname -a | grep -i CYGWIN >/dev/null
32	if [ $? != "0" ]; then
33		echo "ERROR: The Usermin install script must be run as root";
34		echo "";
35		exit 1;
36	fi
37fi
38
39# Use the supplied destination directory, if any
40if [ "$1" != "" ]; then
41	wadir=$1
42	echo "Installing Usermin from $srcdir to $wadir ..."
43	if [ ! -d "$wadir" ]; then
44		mkdir "$wadir"
45		if [ "$?" != "0" ]; then
46			echo "ERROR: Failed to create $wadir"
47			echo ""
48			exit 1
49		fi
50	else
51		# Make sure dest dir is not in use
52		ls "$wadir" | grep -v rpmsave >/dev/null 2>&1
53		if [ "$?" = "0" -a ! -r "$wadir/setup.sh" ]; then
54			echo "ERROR: Installation directory $wadir contains other files"
55			echo ""
56			exit 1
57		fi
58	fi
59else
60	echo "Installing Usermin in $wadir ..."
61fi
62cd "$wadir"
63
64# Display install directory
65allmods=`cd "$srcdir"; echo */module.info | sed -e 's/\/module.info//g'`
66if [ "$allmods" = "" ]; then
67	echo "ERROR: Failed to get module list"
68	echo ""
69	exit 1
70fi
71echo ""
72
73# Load package-defined variable overrides
74if [ -r "$srcdir/setup-pre.sh" ]; then
75        . "$srcdir/setup-pre.sh"
76fi
77
78# Ask for usermin config directory
79echo "***********************************************************************"
80echo "Usermin uses separate directories for configuration files and log files."
81echo "Unless you want to run multiple versions of Usermin at the same time"
82echo "you can just accept the defaults."
83echo ""
84config_dir=/usr/local/etc/usermin
85if [ ! -d $config_dir ]; then
86	mkdir $config_dir;
87	if [ $? != 0 ]; then
88		echo "ERROR: Failed to create directory $config_dir"
89		echo ""
90		exit 2
91	fi
92fi
93if [ -r "$config_dir/config" ]; then
94	echo "Found existing Usermin configuration in $config_dir"
95	echo ""
96	upgrading=1
97fi
98
99# Check if upgrading from an old version
100if [ "$upgrading" = 1 ]; then
101	echo ""
102
103	# Get current var path
104	var_dir=`cat $config_dir/var-path`
105
106	# Force creation if non-existant
107	mkdir -p $var_dir >/dev/null 2>&1
108
109	# Get current perl path
110	perl=`cat $config_dir/perl-path`
111
112	# Create temp files directory
113	$perl "$srcdir/maketemp.pl"
114	if [ "$?" != "0" ]; then
115		echo "ERROR: Failed to create or check temp files directory $tempdir"
116		echo ""
117		exit 2
118	fi
119
120	# Get old os name and version
121	os_type=`grep "^os_type=" $config_dir/config | sed -e 's/os_type=//g'`
122	os_version=`grep "^os_version=" $config_dir/config | sed -e 's/os_version=//g'`
123	real_os_type=`grep "^real_os_type=" $config_dir/config | sed -e 's/real_os_type=//g'`
124	real_os_version=`grep "^real_os_version=" $config_dir/config | sed -e 's/real_os_version=//g'`
125
126	# Get old root, host, port, ssl and boot flag
127	oldwadir=`grep "^root=" $config_dir/miniserv.conf | sed -e 's/root=//g'`
128	port=`grep "^port=" $config_dir/miniserv.conf | sed -e 's/port=//g'`
129	ssl=`grep "^ssl=" $config_dir/miniserv.conf | sed -e 's/ssl=//g'`
130	atboot=`grep "^atboot=" $config_dir/miniserv.conf | sed -e 's/atboot=//g'`
131	inetd=`grep "^inetd=" $config_dir/miniserv.conf | sed -e 's/inetd=//g'`
132
133	if [ "$inetd" != "1" ]; then
134		# Stop old version
135		$config_dir/stop >/dev/null 2>&1
136	fi
137
138	# Copy files to target directory
139	if [ "$wadir" != "$srcdir" ]; then
140		echo "Copying files to $wadir .."
141		(cd "$srcdir" ; tar cf - . | (cd "$wadir" ; tar xf -))
142		echo "..done"
143		echo ""
144	fi
145
146	# Update ACLs
147	$perl "$wadir/newmods.pl" $config_dir $allmods
148
149	# Update miniserv.conf with new root directory and mime types file
150	grep -v "^root=" $config_dir/miniserv.conf | grep -v "^mimetypes=" | grep -v "^server=" >"$tempdir/$$.miniserv.conf"
151	mv "$tempdir/$$.miniserv.conf" "$config_dir/miniserv.conf"
152	echo "root=$wadir" >> $config_dir/miniserv.conf
153	echo "mimetypes=$wadir/mime.types" >> $config_dir/miniserv.conf
154	echo "server=MiniServ/$ver" >> $config_dir/miniserv.conf
155	grep logout= $config_dir/miniserv.conf >/dev/null
156	if [ $? != "0" ]; then
157		echo "logout=$config_dir/logout-flag" >> $config_dir/miniserv.conf
158	fi
159
160	# Check for third-party modules in old version
161	if [ "$wadir" != "$oldwadir" ]; then
162		echo "Checking for third-party modules .."
163		if [ "$webmin_upgrade" != "" ]; then
164			autothird=1
165		fi
166		$perl "$wadir/thirdparty.pl" "$wadir" "$oldwadir" $autothird
167		echo "..done"
168		echo ""
169	fi
170
171	# Remove old cache of module infos
172	rm -f $config_dir/module.infos.cache
173else
174	# Config directory exists .. make sure it is not in use
175	ls $config_dir | grep -v rpmsave >/dev/null 2>&1
176	if [ "$?" = "0" -a "$config_dir" != "/etc/usermin" ]; then
177		echo "ERROR: Config directory $config_dir is not empty"
178		echo ""
179		exit 2
180	fi
181
182	# Ask for log directory
183	printf "Log file directory [/var/log/usermin]: "
184	if [ "$var_dir" = "" ]; then
185		read var_dir
186	fi
187	if [ "$var_dir" = "" ]; then
188		var_dir=/var/log/usermin
189	fi
190	abspath=`echo $var_dir | grep "^/"`
191	if [ "$abspath" = "" ]; then
192		echo "Log file directory must be an absolute path"
193		echo ""
194		exit 3
195	fi
196	if [ "$var_dir" = "/" ]; then
197		echo "Log directory cannot be /"
198		exit ""
199		exit 3
200	fi
201	if [ ! -d $var_dir ]; then
202		mkdir $var_dir
203		if [ $? != 0 ]; then
204			echo "ERROR: Failed to create directory $var_dir"
205			echo ""
206			exit 3
207		fi
208	fi
209	echo ""
210
211	# Ask where perl is installed
212	echo "***********************************************************************"
213	echo "Usermin is written entirely in Perl. Please enter the full path to the"
214	echo "Perl 5 interpreter on your system."
215	echo ""
216	if [ -x /usr/local/bin/perl ]; then
217		perldef=/usr/local/bin/perl
218	elif [ -x /usr/bin/perl ]; then
219		perldef=/usr/bin/perl
220	elif [ -x /usr/local/bin/perl ]; then
221		perldef=/usr/local/bin/perl
222	else
223		perldef=""
224	fi
225	if [ "$perl" = "" ]; then
226		if [ "$perldef" = "" ]; then
227			printf "Full path to perl: "
228			read perl
229			if [ "$perl" = "" ]; then
230				echo "ERROR: No path entered!"
231				echo ""
232				exit 4
233			fi
234		else
235			printf "Full path to perl (default $perldef): "
236			read perl
237			if [ "$perl" = "" ]; then
238				perl=$perldef
239			fi
240		fi
241	fi
242	echo ""
243
244	# Test perl
245	echo "Testing Perl ..."
246	if [ ! -x $perl ]; then
247		echo "ERROR: Failed to find perl at $perl"
248		echo ""
249		exit 5
250	fi
251	$perl -e 'print "foobar\n"' 2>/dev/null | grep foobar >/dev/null
252	if [ $? != "0" ]; then
253		echo "ERROR: Failed to run test perl script. Maybe $perl is"
254		echo "not the perl interpreter, or is not installed properly"
255		echo ""
256		exit 6
257	fi
258	$perl -e 'exit ($] < 5.008 ? 1 : 0)'
259	if [ $? = "1" ]; then
260		echo "ERROR: Detected old perl version. Usermin requires"
261		echo "perl 5.8 or better to run"
262		echo ""
263		exit 7
264	fi
265	$perl -e 'use Socket; print "foobar\n"' 2>/dev/null | grep foobar >/dev/null
266	if [ $? != "0" ]; then
267		echo "ERROR: Perl Socket module not installed. Maybe Perl has"
268		echo "not been properly installed on your system"
269		echo ""
270		exit 8
271	fi
272	$perl -e '$c = crypt("xx", "yy"); exit($c ? 0 : 1)'
273        if [ $? != "0" ]; then
274                $perl -e 'use Crypt::UnixCrypt' >/dev/null 2>&1
275        fi
276	if [ $? != "0" ]; then
277		echo "ERROR: Perl crypt function does not work. Maybe Perl has"
278		echo "not been properly installed on your system"
279		echo ""
280		exit 8
281	fi
282	echo "Perl seems to be installed ok"
283	echo ""
284
285	# Create temp files directory
286	$perl "$srcdir/maketemp.pl"
287	if [ "$?" != "0" ]; then
288		echo "ERROR: Failed to create or check temp files directory $tempdir"
289		echo ""
290		exit 2
291	fi
292
293	# Ask for operating system type
294	echo "***********************************************************************"
295	if [ "$os_type" = "" ]; then
296		if [ "$autoos" = "" ]; then
297			autoos=2
298		fi
299		$perl "$srcdir/oschooser.pl" "$srcdir/os_list.txt" "$tempdir/$$.os" $autoos
300		if [ $? != 0 ]; then
301			exit $?
302		fi
303		. "$tempdir/$$.os"
304		rm -f "$tempdir/$$.os"
305	fi
306	echo "Operating system name:    $real_os_type"
307	echo "Operating system version: $real_os_version"
308	echo ""
309
310	# Ask for web server port, name and password
311	echo "***********************************************************************"
312	echo "Usermin uses its own password protected web server to provide access"
313	echo "to the administration programs. The setup script needs to know :"
314	echo " - What port to run the web server on. There must not be another"
315	echo "   web server already using this port."
316	echo " - If the webserver should use SSL (if your system supports it)."
317	echo ""
318	printf "Web server port (default 20000): "
319	if [ "$port" = "" ]; then
320		read port
321		if [ "$port" = "" ]; then
322			port=20000
323		fi
324	fi
325	if [ $port -lt 1 ]; then
326		echo "ERROR: $port is not a valid port number"
327		echo ""
328		exit 11
329	fi
330	if [ $port -gt 65535 ]; then
331		echo "ERROR: $port is not a valid port number. Port numbers cannot be"
332		echo "       greater than 65535"
333		echo ""
334		exit 12
335	fi
336	if [ "$noportcheck" = "" ]; then
337		$perl -e 'use Socket; socket(FOO, PF_INET, SOCK_STREAM, getprotobyname("tcp")); setsockopt(FOO, SOL_SOCKET, SO_REUSEADDR, pack("l", 1)); bind(FOO, pack_sockaddr_in($ARGV[0], INADDR_ANY)) || exit(1); exit(0);' $port
338		if [ $? != "0" ]; then
339			echo "ERROR: TCP port $port is already in use by another program"
340			echo ""
341			exit 13
342		fi
343	fi
344
345	# Ask the user if SSL should be used
346	if [ "$ssl" = "" ]; then
347		ssl=0
348		$perl -e 'use Net::SSLeay' >/dev/null 2>/dev/null
349		if [ $? = "0" ]; then
350			printf "Use SSL (y/n): "
351			read sslyn
352			if [ "$sslyn" = "y" -o "$sslyn" = "Y" ]; then
353				ssl=1
354			fi
355		else
356			echo "The Perl SSLeay library is not installed. SSL not available."
357			rm -f core
358		fi
359	fi
360
361	# Don't use SSL if missing Net::SSLeay
362	if [ "$ssl" = "1" ]; then
363		$perl -e 'use Net::SSLeay' >/dev/null 2>/dev/null
364		if [ $? != "0" ]; then
365			ssl=0
366		fi
367	fi
368
369	# Copy files to target directory
370	echo "***********************************************************************"
371	if [ "$wadir" != "$srcdir" ]; then
372		echo "Copying files to $wadir .."
373		(cd "$srcdir" ; tar cf - . | (cd "$wadir" ; tar xf -))
374		echo "..done"
375		echo ""
376	fi
377
378	# Create webserver config file
379	echo $perl > $config_dir/perl-path
380	echo $var_dir > $config_dir/var-path
381	echo "Creating web server config files.."
382	cfile=$config_dir/miniserv.conf
383	echo "port=$port" >> $cfile
384	echo "root=$wadir" >> $cfile
385	echo "mimetypes=$wadir/mime.types" >> $cfile
386	echo "addtype_cgi=internal/cgi" >> $cfile
387	echo "realm=Usermin Server" >> $cfile
388	echo "logfile=$var_dir/miniserv.log" >> $cfile
389	echo "errorlog=$var_dir/miniserv.error" >> $cfile
390	echo "pidfile=$var_dir/miniserv.pid" >> $cfile
391	echo "logtime=168" >> $cfile
392	echo "ppath=$ppath" >> $cfile
393	echo "ssl=$ssl" >> $cfile
394	echo "no_ssl2=1" >> $cfile
395	echo "no_ssl3=1" >> $cfile
396	openssl version 2>&1 | grep "OpenSSL 1" 2>&1 >/dev/null
397	if [ "$?" == "0" ]; then
398		echo "no_tls1=1" >> $cfile
399		echo "no_tls1_1=1" >> $cfile
400	fi
401	echo "env_WEBMIN_CONFIG=$config_dir" >> $cfile
402	echo "env_WEBMIN_VAR=$var_dir" >> $cfile
403	echo "atboot=$atboot" >> $cfile
404	echo "logout=$config_dir/logout-flag" >> $cfile
405	echo "listen=20000" >> $cfile
406	echo "denyfile=\\.pl\$" >> $cfile
407	echo "log=1" >> $cfile
408	echo "blockhost_failures=5" >> $cfile
409	echo "blockhost_time=60" >> $cfile
410	if [ "$allow" != "" ]; then
411		echo "allow=$allow" >> $cfile
412	fi
413	if [ "$session" != "" ]; then
414		echo "session=$session" >> $cfile
415	else
416		echo "session=1" >> $cfile
417	fi
418	echo "unixauth=user" >> $cfile
419	echo "pam=usermin" >> $cfile
420	echo premodules=WebminCore >> $cfile
421	echo "server=MiniServ/$ver" >> $cfile
422
423	# Append package-specific info to config file
424	if [ -r "$wadir/miniserv-conf" ]; then
425		cat "$wadir/miniserv-conf" >>$cfile
426	fi
427
428	ufile=$config_dir/miniserv.users
429	echo "user:x:0::" > $ufile
430	chmod 644 $ufile
431	echo "userfile=$ufile" >> $cfile
432
433	kfile=$config_dir/miniserv.pem
434	openssl version >/dev/null 2>&1
435	if [ "$?" = "0" ]; then
436		# We can generate a new SSL key for this host
437		host=`hostname`
438		openssl req -newkey rsa:2048 -x509 -nodes -out "$tempdir/cert" -keyout "$tempdir/key" -days 1825 -sha256 >/dev/null 2>&1 <<EOF
439.
440.
441.
442Usermin Webserver on $host
443.
444*
445root@$host
446EOF
447		if [ "$?" = "0" ]; then
448			cat "$tempdir/cert" "$tempdir/key" >$kfile
449		fi
450		rm -f "$tempdir/cert" "$tempdir/key"
451	fi
452	if [ ! -r $kfile ]; then
453		# Fall back to the built-in key
454		cp "$wadir/miniserv.pem" $kfile
455	fi
456	chmod 600 $kfile
457	echo "keyfile=$config_dir/miniserv.pem" >> $cfile
458
459	chmod 644 $cfile
460	echo "..done"
461	echo ""
462
463	echo "Creating access control file.."
464	defmods=`cat "$wadir/defaultmodules" 2>/dev/null`
465	if [ "$defmods" = "" ]; then
466		defmods="$allmods"
467	fi
468	afile=$config_dir/webmin.acl
469	rm -f $afile
470	echo "user: $defmods" >> $afile
471	chmod 644 $afile
472	echo "..done"
473	echo ""
474
475fi
476
477noperlpath="yes"
478if [ "$noperlpath" = "" ]; then
479	echo "Inserting path to perl into scripts.."
480	(find "$wadir" -name '*.cgi' -print ; find "$wadir" -name '*.pl' -print) | $perl "$wadir/perlpath.pl" $perl -
481	echo "..done"
482	echo ""
483fi
484
485echo "Creating start and stop scripts.."
486rm -f $config_dir/stop $config_dir/start
487echo "#!/bin/sh" >>$config_dir/start
488echo "trap '' 1" >>$config_dir/start
489echo "LANG=" >>$config_dir/start
490echo "export LANG" >>$config_dir/start
491echo "#PERLIO=:raw" >>$config_dir/start
492echo "unset PERLIO" >>$config_dir/start
493echo "export PERLIO" >>$config_dir/start
494uname -a | grep -i 'HP/*UX' >/dev/null
495if [ $? = "0" ]; then
496	echo "exec "$wadir/miniserv.pl" $config_dir/miniserv.conf &" >>$config_dir/start
497else
498	uname -a | grep -i FreeBSD >/dev/null
499	if [ "$?" = "0" ]; then
500		echo "LD_PRELOAD=`echo /usr/lib/libpam.so.?`" >>$config_dir/start
501		echo "export LD_PRELOAD" >>$config_dir/start
502	fi
503	echo "exec "$wadir/miniserv.pl" $config_dir/miniserv.conf" >>$config_dir/start
504fi
505
506echo "#!/bin/sh" >>$config_dir/stop
507echo "echo Stopping Usermin server in $wadir" >>$config_dir/stop
508echo "pidfile=\`grep \"^pidfile=\" $config_dir/miniserv.conf | sed -e 's/pidfile=//g'\`" >>$config_dir/stop
509echo "kill \`cat \$pidfile\`" >>$config_dir/stop
510chmod 755 $config_dir/start $config_dir/stop
511echo "..done"
512echo ""
513
514if [ "$upgrading" = 1 ]; then
515	echo "Updating config files.."
516else
517	echo "Copying config files.."
518fi
519$perl "$wadir/copyconfig.pl" "$os_type" "$os_version" "$wadir" $config_dir "" $allmods
520if [ "$upgrading" != 1 ]; then
521	# Store the OS and version
522	echo "os_type=$os_type" >> $config_dir/config
523	echo "os_version=$os_version" >> $config_dir/config
524	echo "real_os_type=$real_os_type" >> $config_dir/config
525	echo "real_os_version=$real_os_version" >> $config_dir/config
526	echo "lang=en.UTF-8" >> $config_dir/config
527
528	# Set additional usermin-specific options
529	echo "userconfig=.usermin" >> $config_dir/config
530	echo "overlang=ulang" >> $config_dir/config
531	echo "nofeedbackcc=2" >> $config_dir/config
532	echo "nofeedbackconf=1" >> $config_dir/config
533
534	# Disallow unknown referers by default
535	echo "referers_none=1" >> $config_dir/config
536else
537	# Disallow unknown referers if not set
538	grep referers_none= $config_dir/config >/dev/null
539	if [ "$?" != "0" ]; then
540		echo "referers_none=1" >> $config_dir/config
541	fi
542fi
543echo $ver > $config_dir/version
544echo "..done"
545echo ""
546
547# Set passwd_ fields in miniserv.conf from global config
548for field in passwd_file passwd_uindex passwd_pindex passwd_cindex passwd_mindex; do
549	grep $field= $config_dir/miniserv.conf >/dev/null
550	if [ "$?" != "0" ]; then
551		grep $field= $config_dir/config >> $config_dir/miniserv.conf
552	fi
553done
554grep passwd_mode= $config_dir/miniserv.conf >/dev/null
555if [ "$?" != "0" ]; then
556	echo passwd_mode=2 >> $config_dir/miniserv.conf
557fi
558
559# Set usermin-specific SID cookie name
560grep sidname= $config_dir/miniserv.conf >/dev/null
561if [ "$?" != "0" ]; then
562	echo sidname=usid >> $config_dir/miniserv.conf
563fi
564
565# Set a special theme if none was set before
566if [ "$theme" = "" ]; then
567	theme=`cat "$wadir/defaulttheme" 2>/dev/null`
568fi
569oldthemeline=`grep "^theme=" $config_dir/config`
570oldtheme=`echo $oldthemeline | sed -e 's/theme=//g'`
571if [ "$theme" != "" ] && [ "$oldthemeline" = "" ] && [ -d "$wadir/$theme" ]; then
572	echo "theme=$theme" >> $config_dir/config
573	echo "preroot=$theme" >> $config_dir/miniserv.conf
574fi
575
576# Set the product field in the global config
577grep product= $config_dir/config >/dev/null
578if [ "$?" != "0" ]; then
579	echo product=usermin >> $config_dir/config
580fi
581
582# If password delays are not specifically disabled, enable them
583grep passdelay= $config_dir/miniserv.conf >/dev/null
584if [ "$?" != "0" ]; then
585	echo passdelay=1 >> $config_dir/miniserv.conf
586fi
587
588nouninstall="yes"
589if [ "$nouninstall" = "" ]; then
590	echo "Creating uninstall script $config_dir/uninstall.sh .."
591	cat >$config_dir/uninstall.sh <<EOF
592#!/bin/sh
593printf "Are you sure you want to uninstall Usermin? (y/n) : "
594read answer
595printf "\n"
596if [ "\$answer" = "y" ]; then
597	$config_dir/stop
598	echo "Deleting $wadir .."
599	rm -rf "$wadir"
600	echo "Deleting $config_dir .."
601	rm -rf $config_dir
602	echo "Done!"
603fi
604EOF
605	chmod +x $config_dir/uninstall.sh
606	echo "..done"
607	echo ""
608fi
609
610echo "Changing ownership and permissions .."
611chown -R root:bin $config_dir
612find $config_dir -type d -exec chmod 755 {} +
613if [ "$nochown" = "" ]; then
614	chown -R root:bin "$wadir"
615	chmod -R og-w "$wadir"
616	if [ $var_dir != "/var" ]; then
617		chown -R root:bin $var_dir
618		chmod -R og-w $var_dir
619		chmod -R a+rx "$wadir"
620	fi
621fi
622chmod 600 $config_dir/miniserv.pem 2>/dev/null
623echo "..done"
624echo ""
625
626# Save target directory if one was specified
627if [ "$wadir" != "$srcdir" ]; then
628	echo $wadir >$config_dir/install-dir
629else
630	rm -f $config_dir/install-dir
631fi
632
633# Run package-defined post-install script
634if [ -r "$srcdir/setup-post.sh" ]; then
635	. "$srcdir/setup-post.sh"
636fi
637
638nostart="yes"
639if [ "$nostart" = "" ]; then
640	if [ "$inetd" != "1" ]; then
641		echo "Attempting to start Usermin mini web server.."
642		$config_dir/start
643		if [ $? != "0" ]; then
644			echo "ERROR: Failed to start web server!"
645			echo ""
646			exit 14
647		fi
648		echo "..done"
649		echo ""
650	fi
651
652	echo "***********************************************************************"
653	echo "Usermin has been installed and started successfully. Use your web"
654	echo "browser to go to"
655	echo ""
656	host=`hostname`
657	if [ "$ssl" = "1" ]; then
658		echo "  https://$host:$port/"
659	else
660		echo "  http://$host:$port/"
661	fi
662	echo ""
663	echo "and login as any Unix user on your system."
664	echo ""
665	if [ "$ssl" = "1" ]; then
666		echo "Because Usermin uses SSL for encryption only, the certificate"
667		echo "it uses is not signed by one of the recognized CAs such as"
668		echo "Verisign. When you first connect to the Usermin server, your"
669		echo "browser will ask you if you want to accept the certificate"
670		echo "presented, as it does not recognize the CA. Say yes."
671		echo ""
672	fi
673fi
674
675if [ "$oldwadir" != "$wadir" -a "$upgrading" = 1 -a "$deletedold" != 1 ]; then
676	echo "The directory from the previous version of Usermin"
677	echo "   $oldwadir"
678	echo "Can now be safely deleted to free up disk space, assuming"
679	echo "that all third-party modules have been copied to the new"
680	echo "version."
681	echo ""
682fi
683
684