#!/bin/sh DAEMON=sslh DAEMON_LONG_NAME="SSLH" . /etc/init.d/modlibrc config() { modlib_config } start() { modlib_startdaemon $DAEMON_BIN -F /mod/etc/sslh.conf } case $1 in ""|load) [ ! -d /tmp/flash/$DAEMON ] && mkdir -p /tmp/flash/$DAEMON [ ! -e /tmp/flash/$DAEMON/protocols ] && /etc/default.sslh/default-config.sh modlib_add_user_and_group nobody modreg file $DAEMON protocols '$(lang de:"Protokolle" en:"Protocols")' 1 protocols modreg cgi $DAEMON "$DAEMON_LONG_NAME" modreg daemon $DAEMON modlib_start $SSLH_ENABLED ;; unload) modunreg daemon $DAEMON modunreg cgi $DAEMON modunreg file $DAEMON modlib_stop ;; start) modlib_start ;; stop) modlib_stop ;; restart) modlib_restart ;; status) modlib_status ;; *) echo "Usage: $0 [load|unload|start|stop|restart|status]" 1>&2 exit 1 ;; esac exit 0