aboutsummaryrefslogtreecommitdiffstats
path: root/net/sslh/files
diff options
context:
space:
mode:
authorwg <wg@FreeBSD.org>2013-11-07 03:42:20 +0800
committerwg <wg@FreeBSD.org>2013-11-07 03:42:20 +0800
commit1e34b9d0869a99281478c0f99c28f559efd447b4 (patch)
tree35dfc45925ea00361f2c243db7ed61436b263ffb /net/sslh/files
parenta13bc59fe42d92b412756067fd9a7186a768a55f (diff)
downloadfreebsd-ports-gnome-1e34b9d0869a99281478c0f99c28f559efd447b4.tar.gz
freebsd-ports-gnome-1e34b9d0869a99281478c0f99c28f559efd447b4.tar.zst
freebsd-ports-gnome-1e34b9d0869a99281478c0f99c28f559efd447b4.zip
net/sslh: update to 1.15
- Update to 1.15 - Convert lib depends to new format - Remove MANPAGES option - Allow staging PR: ports/183700 Submitted by: Olivier Cochard-Labbe <olivier cochard.me> (maintainer)
Diffstat (limited to 'net/sslh/files')
-rw-r--r--net/sslh/files/patch-Makefile24
-rw-r--r--net/sslh/files/sslh.in35
2 files changed, 8 insertions, 51 deletions
diff --git a/net/sslh/files/patch-Makefile b/net/sslh/files/patch-Makefile
deleted file mode 100644
index df629b2f6e54..000000000000
--- a/net/sslh/files/patch-Makefile
+++ /dev/null
@@ -1,24 +0,0 @@
---- ./Makefile.orig 2012-06-03 02:10:16.959537483 +0200
-+++ ./Makefile 2012-06-03 02:10:20.312769958 +0200
-@@ -4,7 +4,7 @@
- USELIBCONFIG=1 # Use libconfig? (necessary to use configuration files)
- USELIBWRAP= # Use libwrap?
- COV_TEST= # Perform test coverage?
--PREFIX=/usr/local
-+PREFIX ?=/usr/local
-
- MAN=sslh.8.gz # man page name
-
-@@ -15,10 +15,9 @@
- CFLAGS_COV=-fprofile-arcs -ftest-coverage
- endif
-
--CC = gcc
--CFLAGS=-Wall -g $(CFLAGS_COV)
-+CC ?= gcc
-+CFLAGS ?=-Wall -g $(CFLAGS_COV)
-
--LIBS=
- OBJS=common.o sslh-main.o probe.o
-
- ifneq ($(strip $(USELIBWRAP)),)
diff --git a/net/sslh/files/sslh.in b/net/sslh/files/sslh.in
index 16afac2d4bcf..e83dc677b242 100644
--- a/net/sslh/files/sslh.in
+++ b/net/sslh/files/sslh.in
@@ -7,23 +7,17 @@
# PROVIDE: sslh
# REQUIRE: login
# KEYWORD: shutdown
-
#
# Add the following to /etc/rc.conf[.local] to enable this service
#
# sslh_enable="YES"
#
# You can fine tune others variables too:
+# You can fine tune others variables too:
# sslh_mode="fork | select"
# fork: stable but slow performance
# select: new but high performance
-# sslh_pidfile="/var/run/sslh.pid"
-# sslh_ssltarget="localhost:443"
-# sslh_sshtarget="localhost:22"
-# sslh_sshtimeout="2"
-# sslh_listening="0.0.0.0:8443"
-# sslh_uid="nobody"
-# sslh_flags
+# sslh_fib: Routing table number
sslh_precmd() {
if command -v check_namevarlist > /dev/null 2>&1; then
@@ -47,30 +41,17 @@ name="sslh"
rcvar=sslh_enable
start_precmd="sslh_precmd"
-stop_postcmd="sslh_postcmd"
load_rc_config $name
-
sslh_enable=${sslh_enable:-"NO"}
sslh_mode=${sslh_mode:-"fork"}
-sslh_listening=${sslh_listening:-"0.0.0.0:443"}
-sslh_sshtarget=${sslh_sshtarget:-"localhost:22"}
-sslh_ssltarget=${sslh_ssltarget:-"localhost:8443"}
-sslh_sshtimeout=${sslh_sshtimeout:-"2"}
-sslh_openvpntarget=${sslh_openvpntarget:-"localhost:1193"}
-sslh_xmpptarget=${sslh_xmpptarget:-"localhost:5222"}
-sslh_tinctarget=${sslh_tinctarget:-"localhost:655"}
-pidfile=${sslh_pidfile:-"/var/run/sslh.pid"}
-command="%%PREFIX%%/sbin/${name}-${sslh_mode}"
-command_args="-t ${sslh_sshtimeout} -p ${sslh_listening} \
- --ssh ${sslh_sshtarget} --ssl ${sslh_ssltarget} -P ${pidfile} \
- --user nobody --openvpn ${sslh_openvpntarget} \
- --xmpp ${sslh_xmpptarget} --tinc ${sslh_tinctarget}"
+required_files="%%PREFIX%%/etc/${name}.conf"
+for value in listening sshtarget ssltarget sshtimeout openvpntarget xmpptarget tinctarget;do
+ eval "[ -n \"\${sslh_${value}}\" ]" && warn "${name}_${value} no more used: Configuration file available"
+done
-sslh_postcmd()
-{
- rm -f ${pidfile}
-}
+command="%%PREFIX%%/sbin/${name}-${sslh_mode}"
+command_args="-F %%PREFIX%%/etc/${name}.conf"
run_rc_command "$1"