Skip to content

Commit

Permalink
sslh: update to v2.1.4
Browse files Browse the repository at this point in the history
- update sslh
- add sslh-select and sslh-ev to package
  • Loading branch information
hgy59 committed Feb 7, 2025
1 parent 703e74f commit 9f06114
Show file tree
Hide file tree
Showing 6 changed files with 32 additions and 35 deletions.
21 changes: 12 additions & 9 deletions cross/sslh/Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
PKG_NAME = sslh
PKG_VERS = 1.23.1
PKG_VERS = 2.1.4
PKG_EXT = tar.gz
PKG_DIST_NAME = v$(PKG_VERS).$(PKG_EXT)
PKG_DIST_SITE = https://github.com/yrutschle/sslh/archive
Expand All @@ -10,27 +10,30 @@ DEPENDS = cross/libconfig
DEPENDS += cross/pcre2
DEPENDS += cross/tcp_wrappers
DEPENDS += cross/libcap
DEPENDS += cross/libev

# compiller must support -std=c11
# compiler must support -std=c11
UNSUPPORTED_ARCHS = $(ARMv5_ARCHS) $(OLD_PPC_ARCHS)

HOMEPAGE = https://www.rutschle.net/tech/sslh/README.html
COMMENT = Applicative Protocol Multiplexer (e.g. share SSH and HTTPS on the same port).
LICENSE = GPLv2

CONFIGURE_TARGET = nop
GNU_CONFIGURE = 1

INSTALL_TARGET = sslh_install
COMPILE_MAKE_OPTIONS = USELIBWRAP=1 USELIBCAP=1

ADDITIONAL_CFLAGS = -std=c11
# use misc of netdb.h in toolchain to define NI_MAXHOST, NI_MAXSERV, ...
ADDITIONAL_CFLAGS += -D__USE_MISC
ADDITIONAL_CFLAGS += -DNI_MAXHOST=1025
ADDITIONAL_CFLAGS += -DNI_MAXSERV=32
# force definition of __USE_MISC to define NI_MAXHOST, NI_MAXSERV, ... in netdb.h of toolchain
# __USE_MISC is defined in features.h when _DEFAULT_SOURCE is defined (otherwise __USE_MISC is undefined)
ADDITIONAL_CFLAGS += -D_DEFAULT_SOURCE

include ../../mk/spksrc.cross-cc.mk

.PHONY: sslh_install
sslh_install:
@$(RUN) mkdir -p $(STAGING_INSTALL_PREFIX)/bin
@$(RUN) cp $(WORK_DIR)/$(PKG_DIR)/sslh-fork $(STAGING_INSTALL_PREFIX)/bin/sslh
@install -d -m 755 $(STAGING_INSTALL_PREFIX)/bin
@install -m 755 $(WORK_DIR)/$(PKG_DIR)/sslh-fork $(STAGING_INSTALL_PREFIX)/bin/sslh
@install -m 755 $(WORK_DIR)/$(PKG_DIR)/sslh-select $(STAGING_INSTALL_PREFIX)/bin/
@install -m 755 $(WORK_DIR)/$(PKG_DIR)/sslh-ev $(STAGING_INSTALL_PREFIX)/bin/
2 changes: 2 additions & 0 deletions cross/sslh/PLIST
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
bin:bin/sslh
bin:bin/sslh-ev
bin:bin/sslh-select
6 changes: 3 additions & 3 deletions cross/sslh/digests
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
sslh-v1.23.1.tar.gz SHA1 4c856d0179a4c57545f9a0ef5b8d8454131c9f25
sslh-v1.23.1.tar.gz SHA256 6f1c529a3f0cc6733c03e64480c9c480b726fec7328c49dda33af015ac219205
sslh-v1.23.1.tar.gz MD5 da8825b6f99c145f9714177f534ad046
sslh-v2.1.4.tar.gz SHA1 4ec83156e27c4750efbc17a5cba5641f063a22cb
sslh-v2.1.4.tar.gz SHA256 7bf48538f778bb67abbe5a9ba880217c7892fe4c2aefbca93bb788d9e6866236
sslh-v2.1.4.tar.gz MD5 53a074c517bed53c21553ab09c257305
14 changes: 0 additions & 14 deletions cross/sslh/patches/001-include_sys_select_to_avoid_error.patch

This file was deleted.

7 changes: 3 additions & 4 deletions spk/sslh/Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
SPK_NAME = sslh
SPK_VERS = 1.23.1
SPK_VERS = 2.1.4
SPK_REV = 8
SPK_ICON = src/sslh.png

Expand All @@ -8,11 +8,10 @@ DEPENDS = cross/sslh
UNSUPPORTED_ARCHS = $(OLD_PPC_ARCHS) $(ARMv5_ARCHS)

MAINTAINER = SynoCommunity
DESCRIPTION = sslh accepts HTTPS, SSH, OpenVPN, tinc and XMPP connections on the same port. This makes it possible to connect to any of these servers on port 443 \(e.g. from inside a corporate firewall, which almost never block port 443\) while still serving HTTPS on that port.
DESCRIPTION_FRE = sslh accepte des connexions HTTPS, SSH, OpenVPN, tinc et XMPP sur le même port TCP. Il est ainsi possible de se connecter à l\'un de ces services sur le port 443 \(par exemple depuis derrière un firewall d\'entrepise qui ne bloque en général pas le port 443\) tout en préservant les accès HTTPS sur ce même port.
DESCRIPTION = sslh is a ssl/ssh multiplexer. sslh accepts connections on specified ports, and forwards them further based on tests performed on the first data packet sent by the remote client. Probes for HTTP, TLS/SSL \(including SNI and ALPN\), SSH, OpenVPN, tinc, XMPP, SOCKS5, are implemented, and any other protocol that can be tested using a regular expression, can be recognised. A typical use case is to allow serving several services on port 443 \(e.g. to connect to SSH from inside a corporate firewall, which almost never block port 443\) while still serving HTTPS on that port.

DISPLAY_NAME = sslh
CHANGELOG = "Update sslh to v1.23.1."
CHANGELOG = "1. Update sslh to v2.1.4. <br/>2. Add sslh-select and sslh-ev."

HOMEPAGE = https://www.rutschle.net/tech/sslh/README.html
LICENSE = GPLv2
Expand Down
17 changes: 12 additions & 5 deletions spk/sslh/src/sslh.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -6,20 +6,27 @@ transparent: false;
timeout: "5";
user: "sc-sslh";
pidfile: "/var/packages/sslh/var/sslh.pid";
logfile: "/var/packages/sslh/var/sslh.log";


# Change hostname with your external address name.
# Change hostname with your external address name, or the IP
# of the interface that receives connections
# Default is to bind all interfaces. httpd can be started
# first to bind on localhost, in which case sslh will bind
# only other interfaces.
listen:
(
{ host: "0.0.0.0"; port: "30000"; }
);

# Change to the protocols you want to forward to. The
# defaults here are sensible for services running on
# localhost
protocols:
(
{ name: "ssh"; service: "ssh"; host: "localhost"; port: "22"; keepalive: true; fork: true; },
{ name: "tls"; host: "localhost"; port: "443"; log_level: 0; },
{ name: "ssh"; service: "ssh"; host: "localhost"; port: "22"; fork: true; },
{ name: "openvpn"; host: "localhost"; port: "1194"; },
{ name: "tinc"; host: "localhost"; port: "655"; },
{ name: "xmpp"; host: "localhost"; port: "5223"; }
{ name: "tls"; host: "localhost"; port: "443"; log_level: 0; },
{ name: "anyprot"; host: "localhost"; port: "443"; }
);

0 comments on commit 9f06114

Please sign in to comment.