Live data from Hacker News

Large scale Internet SSH brute force attacks seem to have stopped here

utcc.utoronto.ca

61–70 of 127 posts

Re: Large scale Internet SSH brute force attacks seem to have stopped here

#61
post #43

Earlier quoted context omitted.

Doesnt fail2ban have an option that will automatically send out abuse complaints for you?

There's something ironic about that. A bot tries to mass ssh login on entire subnets. A bot on one machine blocks the first bot and notified their hosting provider. A bot on the hosting provider responds with a web form for reporting abuse. A bot tries to fill out the web form, but is hit with a captcha.

Its bots all the way down!

Re: Large scale Internet SSH brute force attacks seem to have stopped here

#62
> [...] blocking of only a few IPs is disproportionately effective at stopping brute force SSH attacks here. Also, since we already block Internet logins to 'root', we're in almost no danger. No matter how many times they try, they have literally no chance of success.

This assumes OpenSSH, OpenSSL and other things in between the client and the server don't have ready to exploit security vulnerabilities. These large-scale scanners are a long term investment when there's a zero-day vulnerability to exploit in OpenSSL etc. That's why a layered/defense-in-depth approach is preferable.

Re: Large scale Internet SSH brute force attacks seem to have stopped here

#63
post #14
post #6

Funny - I had noticed something similar in the last couple of months, but hadn't though to look in to it more. I was seeing 30,000 to 50,000 attempts a day, but over the last two weeks, it's around 10,000. Perhaps it's like mining cryptocurrency - all the low hanging fruit has been found, so there's hardly much sense in continuing to waste resources looking for more.

Is it possible the majority of attempts were actually being run by a single botnet, and it either shut down or the owner changed the attack payload? Perhaps it's just been running for the last few years, with the botmaster apathetic, forgetting about it or maybe even had lost control. I think you're right about the low-hanging fruit part: it seems unlikely anyone would bother to put serious effort or money (eg: the r…

> Is it possible the majority of attempts were actually being run by a single botnet, and it either shut down or the owner changed the attack payload?

Russia is preoccupied.

Re: Large scale Internet SSH brute force attacks seem to have stopped here

#64
If you setup Fail2Ban and/or switch SSH from the default port 22 to something in the low 5 digits, then you should get very few attacks.

Someone above talked about using layered/defense-in-depth approach to avoid zero-days and that's also a good idea, but it's more involved / sometimes impractical.

Re: Large scale Internet SSH brute force attacks seem to have stopped here

#65
post #39

I still see them. They come and go, but are always present at some level. 2022-08-29T17:35:12.617Z [DEBUG] sshlog gen 113.61.219.237 admin admin SSH-2.0-HELLOWORLD 2022-08-29T17:48:17.879Z [DEBUG] sshlog gen 218.92.0.190 root poohbear SSH-2.0-PUTTY 2022-08-29T17:48:18.041Z [DEBUG] sshlog gen 218.92.0.190 root p@ssw0rd3 SSH-2.0-PUTTY 2022-08-29T17:48:18.2Z [DEBUG] sshlog gen 218.92.0.190 root p@ssword! SSH-2.0-PUTTY 2…

May I ask how to configure the sshd to generate logs like yours? I searched for it and could not find much information.

Re: Large scale Internet SSH brute force attacks seem to have stopped here

#66

If you setup Fail2Ban and/or switch SSH from the default port 22 to something in the low 5 digits, then you should get very few attacks. Someone above talked about using layered/defense-in-depth approach to avoid zero-days and that's also a good idea, but it's more involved / sometimes impractical.

I did a small study on brute force ssh attacks a couple of years back. Switching the port does a really good job dodging brute force attacks, as long as you don't use 2222. Paradoxically, port 2200 appeared to be a safe choice.

Re: Large scale Internet SSH brute force attacks seem to have stopped here

#67

I'm still seeing the same number of attempts on my public SFTP servers. As a funny side note I found that by going through the hardening steps on ssh-audit [1], most of the bots can't even negotiate a connection. I only see them because I configured verbose logging. They seem to be using really old ssh libraries in the bot code that severely limit the ciphers available to them. Another interesting side effect is that…

You are correct about the libraries not supporting modern ssh :)

I ran a bunch of honeypots for a while and grabbed hassh (like ja3 but for ssh) signatures, most bots are using old fucking libssh/libssh2/paramiko that simply can't talk to modern hosts.

Re: Large scale Internet SSH brute force attacks seem to have stopped here

#68
We have take the approach that the only ports visible to internet traffic are un-authenticated ones... everything else must traverse ipsec or wireguard. This gives us completely silent ssh ports.

We found strongswan examples pretty useful... it's basically pick your config and copy/paste. Wireguard only has 'one way' to set it up which is a whole 'nother level of simplicity.

This has completely silenced our firewall and ssh logs. Nobody is out blasting ipsec or wireguard connection probes around the internet (for now).

Re: Large scale Internet SSH brute force attacks seem to have stopped here

#69
post #23

Fail2ban blocked 1087 ip addresses in the last week, which seems normal. I reset it and it has blocked eleven ip addresses in the last hour, mainly China and Digital Ocean as usual. Just to see what happens, I'v tried sending abuse reports about ssh brute force, vnc brute force and phishing sites, by the standard method of doing a whois lookup on the ip for the abuse email address. Some server and web hosting compani…

I had a DigitalOcean droplet running Selenium grid that I didn't secure properly. I got an email that Sony Entertainment had reported my IP for botting login attempts in the Playstation store. I think I had 48 hours to respond to DigitalOcean.

Shut down Selenium right away, checked the logs, yep someone had taken over my selenium grid. It was just a small personal project on a sever I had forgot was still running, but at least they took reports seriously when my account was causing things.

Re: Large scale Internet SSH brute force attacks seem to have stopped here

#70

Did someone record which username/passwords those bots try? I never bothered with that.

I used to do that on my honeypots.

I'll do it again when I set up new ones, it was neat seeing a new credential pair show up from one attacker only for a while, then show up from more over time as knowledge of some appliances default creds spread across the hacker world.

Post reply on HN