From dc7cbdfa65fd814b3b9aa3c56257da201109e807 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Fri, 5 Apr 2019 21:17:31 +0100 Subject: gentoo resync : 05.04.2019 --- net-misc/endlessh/files/endlessh.confd | 22 ++++++++++++++++++++++ net-misc/endlessh/files/endlessh.initd | 22 ++++++++++++++++++++++ net-misc/endlessh/files/logrotated | 7 +++++++ 3 files changed, 51 insertions(+) create mode 100644 net-misc/endlessh/files/endlessh.confd create mode 100755 net-misc/endlessh/files/endlessh.initd create mode 100644 net-misc/endlessh/files/logrotated (limited to 'net-misc/endlessh/files') diff --git a/net-misc/endlessh/files/endlessh.confd b/net-misc/endlessh/files/endlessh.confd new file mode 100644 index 000000000000..a114889c8cac --- /dev/null +++ b/net-misc/endlessh/files/endlessh.confd @@ -0,0 +1,22 @@ +# /etc/conf.d/endlessh: config file for /etc/init.d/endlessh +# +#ENDLESSH_ARGS="" +# +# -d INT Message millisecond delay [10000] +# -f Set and load config file [/etc/endlessh/config] +# -l INT Maximum banner line length (3-255) [32] +# -m INT Maximum number of clients [4096] +# -p INT Listening port [2222] +# -v Print diagnostics to standard output (repeatable) + +# EXAMPLE: listen on port 22, log all queries and errors in very verbose mode + +#ENDLESSH_ARGS="-p 22 -vv" + +# plain file (preferred), change logrotate file as well if you change this. +#output_log=/var/log/"${RC_SVCNAME}.log" +#error_log=/var/log/"${RC_SVCNAME}.error.log" + +# syslog support via LOGGER(1). Note this spawns logger processes per io stream +#output_logger="logger -p daemon.none --" +#error_logger="logger -p daemon.err --" diff --git a/net-misc/endlessh/files/endlessh.initd b/net-misc/endlessh/files/endlessh.initd new file mode 100755 index 000000000000..a88fd9c34c90 --- /dev/null +++ b/net-misc/endlessh/files/endlessh.initd @@ -0,0 +1,22 @@ +#!/sbin/openrc-run +# Copyright 2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +depend() { + need localmount + use net +} + +description="Starts endlessh tarpit" + +command="/usr/bin/endlessh" +command_args="${ENDLESSH_ARGS}" +command_background="true" +extra_started_commands="reload" +pidfile="/run/${RC_SVCNAME}.pid" + +reload() { + ebegin "Reloading ${RC_SVCNAME} configuration" + start-stop-daemon --exec $command --signal HUP + eend $? +} diff --git a/net-misc/endlessh/files/logrotated b/net-misc/endlessh/files/logrotated new file mode 100644 index 000000000000..53c9efbfe873 --- /dev/null +++ b/net-misc/endlessh/files/logrotated @@ -0,0 +1,7 @@ +/var/log/endlessh.log /var/log/endlessh.error.log { + missingok + notifempty + postrotate + /etc/init.d/endlessh -q reload + endscript +} -- cgit v1.2.3