sysutils/tmate-ssh-server: revive port and update

This commit is contained in:
swills
2020-07-17 04:36:30 +00:00
parent 17d9d34e0f
commit 3e1868fbb2
6 changed files with 80 additions and 0 deletions
+26
View File
@@ -0,0 +1,26 @@
# $FreeBSD$
PORTNAME= tmate-ssh-server
PORTVERSION= g2020071601
PORTEPOCH= 1
CATEGORIES= sysutils
MAINTAINER= swills@FreeBSD.org
COMMENT= Instant terminal sharing server
LIB_DEPENDS= libevent.so:devel/libevent \
libmsgpackc.so:devel/msgpack \
libssh.so:security/libssh
USES= autoreconf ncurses pkgconfig
USE_GITHUB= yes
GH_ACCOUNT= tmate-io
GH_TAGNAME= 97d2024
GNU_CONFIGURE= yes
USE_LDCONFIG= yes
LDFLAGS+= -lexecinfo
PLIST_FILES= bin/tmate-ssh-server
.include <bsd.port.mk>
+3
View File
@@ -0,0 +1,3 @@
TIMESTAMP = 1594956880
SHA256 (tmate-io-tmate-ssh-server-g2020071601-97d2024_GH0.tar.gz) = 76769310d2b8741ef8d0f15390f167b2ed5d0def9e4ad4095805ccb360eead9e
SIZE (tmate-io-tmate-ssh-server-g2020071601-97d2024_GH0.tar.gz) = 623861
@@ -0,0 +1,15 @@
--- tmate-daemon-decoder.c.orig 2019-02-01 22:30:53 UTC
+++ tmate-daemon-decoder.c
@@ -39,11 +39,11 @@ static void tmate_header(struct tmate_session *session
tmate_notify("Note: clear your terminal before sharing readonly access");
tmate_notify("ssh session read only: %s", tmp);
+ tmate_set_env("tmate_ssh_ro", tmp);
sprintf(tmp, "ssh%s %s@%s", port_arg, session->session_token, tmate_settings->tmate_host);
tmate_notify("ssh session: %s", tmp);
- tmate_set_env("tmate_ssh_ro", tmp);
tmate_set_env("tmate_ssh", tmp);
tmate_send_client_ready();
@@ -0,0 +1,10 @@
--- tmate-proxy.c.orig 2016-04-26 08:05:24 UTC
+++ tmate-proxy.c
@@ -2,6 +2,7 @@
#include <netinet/tcp.h>
#include <fcntl.h>
#include <errno.h>
+#include <netinet/in.h>
#include "tmate.h"
#include "tmate-protocol.h"
@@ -0,0 +1,23 @@
--- tmate-ssh-server.c.orig 2020-04-27 23:54:26 UTC
+++ tmate-ssh-server.c
@@ -242,6 +242,12 @@ static void client_bootstrap(struct tmate_session *_se
ssh_options_set(session, SSH_OPTIONS_TIMEOUT, &grace_period);
ssh_options_set(session, SSH_OPTIONS_COMPRESSION, "yes");
+ ssh_options_set(session, SSH_OPTIONS_KEY_EXCHANGE, "curve25519-sha256@libssh.org,diffie-hellman-group18-sha512,diffie-hellman-group14-sha256,diffie-hellman-group16-sha512");
+ ssh_options_set(session, SSH_OPTIONS_CIPHERS_C_S, "aes256-gcm@openssh.com,aes128-gcm@openssh.com,chacha20-poly1305@openssh.com,aes256-ctr,aes192-ctr,aes128-ctr");
+ ssh_options_set(session, SSH_OPTIONS_CIPHERS_S_C, "aes256-gcm@openssh.com,aes128-gcm@openssh.com,chacha20-poly1305@openssh.com,aes256-ctr,aes192-ctr,aes128-ctr");
+ ssh_options_set(session, SSH_OPTIONS_HMAC_S_C, "hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com,umac-128-etm@openssh.com");
+ ssh_options_set(session, SSH_OPTIONS_HMAC_C_S, "hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com,umac-128-etm@openssh.com");
+ ssh_options_set(session, SSH_OPTIONS_HOSTKEYS, "ecdsa-sha2-nistp384-cert-v01@openssh.com,ecdsa-sha2-nistp521-cert-v01@openssh.com,ssh-ed25519-cert-v01@openssh.com,ssh-rsa-cert-v01@openssh.com,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521,ssh-ed25519,ssh-rsa");
ssh_set_auth_methods(client->session, SSH_AUTH_METHOD_NONE |
SSH_AUTH_METHOD_PUBLICKEY);
@@ -417,7 +423,6 @@ static ssh_bind prepare_ssh(const char *keys_dir, cons
ssh_bind_options_set(bind, SSH_BIND_OPTIONS_BANNER, TMATE_SSH_BANNER);
ssh_bind_options_set(bind, SSH_BIND_OPTIONS_LOG_VERBOSITY, &ssh_log_level);
- ssh_import_key(bind, keys_dir, "ssh_host_rsa_key");
ssh_import_key(bind, keys_dir, "ssh_host_ed25519_key");
if (ssh_bind_listen(bind) < 0)
+3
View File
@@ -0,0 +1,3 @@
Instant terminal sharing - server
WWW: https://tmate.io/