Tarpit-Endlessh: Monitors port 2222 instead of port 22

pl flag

I installed on Ubuntu 22.04 tarpit-endlessh (apt install endlessh) and made the following settings in /etc/endlessh/config:

port 22
Delay 10000
MaxLineLength 32
MaxClients 4096
LogLevel 0
BindFamily 0
ss -tulpen | grep ssh

shows me that endlessh it is set to port 2222. Why is port 2222 being watched even though I have port 22 set in endlessh config?

And there is only a empty endlessh.service file in /etc/systemd/system/ Instead the non-empty endlessh.service file is in /lib/systemd/system/

Here /etc/systemd/system/endlessh.service I made these changes:

If you want Endlessh to bind on ports < 1024

  1. run:
setcap 'cap_net_bind_service=+ep' /usr/local/bin/endlessh
  1. uncomment following line
  1. comment following line

However this did not work:

setcap 'cap_net_bind_service=+ep' /usr/local/bin/endlessh

I get this:

Failed to set capabilities on file `/usr/local/bin/endlessh' (No such file or directory) The value of the capability argument is not permitted for a file. Or the file is not a regular (non-symlink) file

Edit: After

systemctl daemon-reload

it monitors Port 22 now. Although this command still don't work:

setcap 'cap_net_bind_service=+ep' /usr/local/bin/endlessh

Why most Tutorials about Endlessh write to compile it from git instead to install it easily with apt install endlessh?

it flag

The port 22 specification is read from the config file upon program startup. Once you've changed the config file, you must restart the program to get it to read the new, improved, config file.

I sit in a Tesla and translated this thread with Ai:


Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.