summaryrefslogtreecommitdiff
path: root/community/sslh
diff options
context:
space:
mode:
Diffstat (limited to 'community/sslh')
-rw-r--r--community/sslh/PKGBUILD14
-rw-r--r--community/sslh/sslh.conf3
-rw-r--r--community/sslh/sslh.rc34
3 files changed, 44 insertions, 7 deletions
diff --git a/community/sslh/PKGBUILD b/community/sslh/PKGBUILD
index 1a3c77533..55a3b9402 100644
--- a/community/sslh/PKGBUILD
+++ b/community/sslh/PKGBUILD
@@ -5,18 +5,18 @@
pkgname=sslh
pkgver=1.10
-pkgrel=3
+pkgrel=4
pkgdesc='SSL/SSH/OpenVPN/XMPP/tinc port multiplexer'
arch=('i686' 'x86_64')
url='http://www.rutschle.net/tech/sslh.shtml'
license=('GPL2')
backup=('etc/conf.d/sslh')
source=("http://www.rutschle.net/tech/${pkgname}-${pkgver}.tar.gz"
- 'rc.sslh'
- 'conf.sslh')
+ 'sslh.rc'
+ 'sslh.conf')
md5sums=('bc34e9a4770d634633e70589c72708cc'
- '1ad105ad572284fa137d06ae8d1f16fc'
- 'e9b05de9d626803e35f46bdd1e968421')
+ '42f3cda8f18abdf5edcd762e6dcda5d7'
+ '8275b5dd363891139398be1d0e92dd57')
build() {
cd $pkgname-$pkgver
@@ -27,8 +27,8 @@ build() {
}
package() {
- install -D -m 755 rc.sslh "${pkgdir}/etc/rc.d/sslh"
- install -D -m 644 conf.sslh "${pkgdir}/etc/conf.d/sslh"
+ install -D -m 755 sslh.rc "${pkgdir}/etc/rc.d/sslh"
+ install -D -m 644 sslh.conf "${pkgdir}/etc/conf.d/sslh"
cd $pkgname-$pkgver
make PREFIX="$pkgdir/usr" install
}
diff --git a/community/sslh/sslh.conf b/community/sslh/sslh.conf
new file mode 100644
index 000000000..2c4e676a8
--- /dev/null
+++ b/community/sslh/sslh.conf
@@ -0,0 +1,3 @@
+# vim:set ts=2 sw=2 ft=sh noet:
+
+DAMEON_OPTIONS='-p 192.168.0.1:443 --ssh 127.0.0.1:22 --ssl 127.0.0.1:443 -u nobody -P /var/lock/sslh.lock'
diff --git a/community/sslh/sslh.rc b/community/sslh/sslh.rc
new file mode 100644
index 000000000..1532b8c10
--- /dev/null
+++ b/community/sslh/sslh.rc
@@ -0,0 +1,34 @@
+#!/bin/bash
+
+. /etc/rc.conf
+. /etc/rc.d/functions
+. /etc/conf.d/${0##*/}
+
+NAME=sslh
+DAEMON=/usr/sbin/sslh
+PID=$(pidof -o %PPID $DAEMON)
+
+case "$1" in
+ start)
+ stat_busy "Starting $NAME daemon"
+ [[ ! $PID ]] && $DAEMON $DAEMON_OPTIONS && add_daemon $NAME && stat_done && exit 0
+ stat_fail
+ ;;
+ stop)
+ stat_busy "Stopping $NAME daemon"
+ [[ $PID ]] && kill $PID &> /dev/null && rm_daemon $NAME && stat_done && exit 0
+ stat_fail
+ ;;
+ restart)
+ $0 stop
+ $0 start
+ exit 0
+ ;;
+ *)
+ echo "usage: ${0##*/} {start|stop|restart}" >&2
+ ;;
+esac
+
+exit 1
+
+# vim:set ts=2 sw=2 ft=sh noet: