From ed75026f1fd95658603d60a40390c6e81cadf2ae Mon Sep 17 00:00:00 2001 From: hubertf Date: Fri, 3 May 2002 22:02:49 +0000 Subject: Update silc-server pkg to 0.8.4. Changes: changes in silc-server package: =============================== - upgraded to version 0.8.4 - added generic startup script for Solaris and Linux (i can't test it on Darwin/Mac OS X because i don't have any.. please let me know if it works for you. thanks) You will need to copy ${PREFIX}/etc/rc.d/silcd to appropriate location in your system and do neccessary actions to enable it. e.g. Solaris: copy ${PREFIX}/etc/rc.d/silcd to /etc/init.d/ and make links in /etc/rc2.d/, /etc/rc1.d/, /etc/rc0.d/. changes in silc-server since 0.8.1: =================================== * Fixed a bug in library where sending a bogus authentication payload would lead to a crash. * Fixed a bug in the fetch_logging() config callback. * Drop root privileges when started in foreground. Don't drop them if debugging also. * Added better error logging in rekey protocol. * Do not check public key types in SKE during rekey. * Fixed the rekey protocol with PFS, which was totally broken. * Fixed a negative refcount situtuation for the config context. * Fixed memory leaks from config object. * Added support for adding new connections to the server in rehash. After rehash they take effect. * Added support for changing the maximum allowed connections in rehash. The number can grow but going smaller is not supported. * Added preliminary checking during config parsing for a valid public/private key and removed further checks in the code. * Fixed silc_net_gethostbyaddr to correctly resolve by address. * Fixed the notify relaying to client. The HMAC to be used with relayed packets ws wrong and caused decryption failure at the client end. * Fixed the silc_log_quick handling in the logging routines. It didn't log quickly when it was TRUE. Also the flush delay was set even if it was 0 in config file. * Added support for changing key pair of the server in rehash. * Fixed the TOPIC_SET notify to not crash. It changed the topic too early, before getting the channel entry. * Added rehash support. Added function silc_server_rehash() that will perform all the basic tasks of the rehashing procedure. * Added command line option `-x, --hexdump'. This will enable the SILC_LOG_HEXDUMP calls that are no longer enabled with `--debug'. The option `--hexdump' implies `--debug'. * Fixed a bad bug in the logging APIs (silcutil library) where the application would crash after calling silc_log_reset_all(). Contributed by Lubomir Sedlacik in PR 16612 --- chat/silc-server/Makefile | 11 +++-- chat/silc-server/distinfo | 6 +-- chat/silc-server/files/silcd.generic | 82 ++++++++++++++++++++++++++++++++++++ chat/silc-server/files/silcd.sh | 4 +- 4 files changed, 95 insertions(+), 8 deletions(-) create mode 100644 chat/silc-server/files/silcd.generic diff --git a/chat/silc-server/Makefile b/chat/silc-server/Makefile index 6909c8431cb..48bbccfafec 100644 --- a/chat/silc-server/Makefile +++ b/chat/silc-server/Makefile @@ -1,6 +1,6 @@ -# $NetBSD: Makefile,v 1.9 2002/03/29 11:34:51 rh Exp $ +# $NetBSD: Makefile,v 1.10 2002/05/03 22:02:49 hubertf Exp $ -DISTNAME= silc-server-0.8.1 +DISTNAME= silc-server-0.8.4 CATEGORIES= chat MASTER_SITES= http://www.silcnet.org/download/server/sources/ \ ftp://ftp.silcnet.org/silc/server/sources/ \ @@ -52,8 +52,8 @@ DEINSTALL_EXTRA_TMPL= ${PKGDIR}/DEINSTALL CONFIGURE_ARGS+= --with-docdir=${PREFIX}/share/doc/silcd CONFIGURE_ARGS+= --with-etcdir=${PKG_SYSCONFDIR} CONFIGURE_ARGS+= --with-silcd-config-file=${PKG_SYSCONFDIR}/silcd.conf -CONFIGURE_ARGS+= --with-silcd-pid-file=/var/run/silcd.pid CONFIGURE_ARGS+= --with-logsdir=/var/log/silcd +CONFIGURE_ARGS+= --with-silcd-pid-file=/var/log/silcd/silcd.pid CONFIGURE_ARGS+= --without-ncurses # list it into IPv6-ready packages @@ -69,8 +69,13 @@ CONFIGURE_ARGS+= --disable-asm .endif post-install: +.if (${OPSYS} == "NetBSD") @${SED} ${FILES_SUBST_SED} ${FILESDIR}/silcd.sh \ > ${PREFIX}/share/doc/silcd/silcd.default +.else + @${SED} ${FILES_SUBST_SED} ${FILESDIR}/silcd.generic \ + > ${PREFIX}/share/doc/silcd/silcd.default +.endif @${SED} ${FILES_SUBST_SED} ${FILESDIR}/motd.txt \ > ${PREFIX}/share/doc/silcd/motd.txt.default diff --git a/chat/silc-server/distinfo b/chat/silc-server/distinfo index a09cdb655fd..dc75aec118b 100644 --- a/chat/silc-server/distinfo +++ b/chat/silc-server/distinfo @@ -1,6 +1,6 @@ -$NetBSD: distinfo,v 1.9 2002/03/29 11:34:51 rh Exp $ +$NetBSD: distinfo,v 1.10 2002/05/03 22:02:49 hubertf Exp $ -SHA1 (silc-server-0.8.1.tar.bz2) = fe2f3e677c5ef1580a888aa5b3c5b01ea229cca0 -Size (silc-server-0.8.1.tar.bz2) = 931438 bytes +SHA1 (silc-server-0.8.4.tar.bz2) = 1549594faa6f21b760f4240ae167bc501efa3101 +Size (silc-server-0.8.4.tar.bz2) = 940368 bytes SHA1 (patch-aa) = 97ccff02e5d2d1bd3ff64a1a1942525e5a4522bd SHA1 (patch-ab) = 482b7580cb95a0833c85f64a3d94c16b2b1c984f diff --git a/chat/silc-server/files/silcd.generic b/chat/silc-server/files/silcd.generic new file mode 100644 index 00000000000..c8280e49670 --- /dev/null +++ b/chat/silc-server/files/silcd.generic @@ -0,0 +1,82 @@ +# $NetBSD: silcd.generic,v 1.1 2002/05/03 22:02:49 hubertf Exp $ +# + +KILL="/bin/kill" +CAT="/bin/cat" +RM="/bin/rm" + +name="silcd" +confdir="@PKG_SYSCONFDIR@" +required_files="$confdir/silcd.conf" +required_dirs="/var/log/silcd" +pidfile="/var/log/silcd/${name}.pid" +command="@PREFIX@/sbin/silcd" +start_precmd="silcd_precmd" + +silcd_precmd() { + if [ ! -f $confdir/silcd.prv ]; then + $command -C $confdir + fi +} + +silcd_start() { + if [ ! -r $required_files ]; then + echo "$0: WARNING: $required_files is not readable." + exit 1 + fi + if [ ! -d $required_dirs ]; then + echo "$0: WARNING: $required_dirs is not a directory." + exit 1 + fi + + eval $start_precmd + return_code=$? + if [ $return_code != "0" ]; then + exit 1 + fi + + echo "Starting ${name}." + eval $command + return_code=$? + if [ $return_code != "0" ]; then + exit 1 + fi +} + + +silcd_stop() { + if [ -r $pidfile -a ! -z $pidfile ]; then + _pid=`${CAT} ${pidfile}` + else + echo "${name} not running?" + fi + if [ ${_pid:=0} -gt 1 -a ! "X$_pid" = "X " ]; then + echo "Stopping ${name}." + ${KILL} ${_pid} + return_code=$? + if [ $return_code != "0" ]; then + exit 1 + fi + fi + ${RM} -f $pidfile +} + +case $1 in + +'start') + silcd_start + ;; + +'stop') + silcd_stop + ;; + +'restart') + silcd_stop + silcd_start + ;; + +*) + echo "Usage: $0 (start|stop|restart)" + ;; +esac diff --git a/chat/silc-server/files/silcd.sh b/chat/silc-server/files/silcd.sh index 91ba94bded0..60c255c95b9 100644 --- a/chat/silc-server/files/silcd.sh +++ b/chat/silc-server/files/silcd.sh @@ -1,6 +1,6 @@ #!/bin/sh # -# $NetBSD: silcd.sh,v 1.3 2002/01/26 14:43:17 hubertf Exp $ +# $NetBSD: silcd.sh,v 1.4 2002/05/03 22:02:49 hubertf Exp $ # # PROVIDE: silcd # REQUIRE: DAEMON @@ -15,7 +15,7 @@ rcvar=$name confdir="@PKG_SYSCONFDIR@" required_files="$confdir/silcd.conf" required_dirs="/var/log/silcd" -pidfile="/var/run/${name}.pid" +pidfile="/var/log/silcd/${name}.pid" command="@PREFIX@/sbin/silcd" start_precmd="silcd_precmd" stop_cmd="silcd_stop" -- cgit v1.2.3