That doesn't look to me like it would find many real credentials. It is collecting the credentials that automated bots are trying to use, some of them, perhaps many of them, will be credentials that someone somewhere is using for something, but unless you are planning an Internet wide scan yourself using those credentials to try login to something is likely to be fruitless.
I'd be more curious to know what these SSH scanner bots actually do if they manage to log in. Automated recon, install spambot/cryptominer/phishing site, something else?
I'm not sure about less targetted bots, but I gave a friend an account on my media server without locking off shell access (which she had no need for), and it turns out that she used the same password as she used for every other service. Something got hold of those (that something must have run on her machine while she was on my network as it was not an externally connectable service) found the account with that user+pass and got in.
I noticed PDQ because of a sudden and fairly constant flow of upstream data that was unusual from that machine, and finding the account & processes involved was easy. As well as installing something to run SSH scans (presumably for further propagation) and running what looked like a crypto-miner, it seemed to be forwarding HTTP(S) requests in a manner that suggested the machine had become part of a “residential proxy” network or similar. Maybe if it hadn't been so greedy I wouldn't have noticed so soon (it hadn't been able to, or hand't tried to, cover its traces, so I found the time of installation very easily as the account otherwise had no SSH activity).
Luckily there were no open root escalation attacks at the time (at least that it knew about) so I only needed to pave that account to get rid of everything, but combined with one of the LPE attacks that have been around over the years it could have caused me much more of a headache.
- If anything looks interesting on their console they will log in and poke around. The order of these events depends on the sophistication of the bot script. Most are very simple.
If you the target look like you have money they may install ransomware and encrypt some of your files. Now I want to watch the Beekeeper again as corny as it was, also a fun movie.
Last time I saw this an obscure single letter root password was still "secure", now days seems like almost all non-alphanumeric chars works. % is my new root password it still has not been brute forced.
There's no such thing as an account with or without login permissions. Normally you need a git account. And that means you can log in to it. And then you have to try and configure your ssh server so that after logging into the git account, you can only run the git server (I forget the command). If a mistake is made with this configuration then you can log in or port forward or X forward or file transfer as git.
This is a terrible idea because it's blacklist-based security. Places like GitHub have their own ssh server that only runs the git server and nothing else.
That's a hack. It's a login shell that, once you have already logged in and run the shell, prints a message saying you can't log in or run a shell, and then exits.
It does not stop you from, say, logging in to SSH and then starting a port forward. Or running a command in a way that bypasses the login shell. ssh will always pass it to your login shell but other ways can be vulnerable.
Do you have a script to show us how it works? Here, use mine. There's no password. Only 1 person permitted on your keyboard. If you have two people typing on it at the same time that's cheating.
Back when it was called Backtrack if my memory serves right. I remember being puzzled that it was not the case anymore one day and they even switched to regular user around when Kali became a thing
I would occasionally scan the auth.log to see which users the bots were using and it was an interesting mix of:
- service accounts e.g. mysql, admin, etc
- individual names e.g. tom, ankit, alexei etc
I noticed PDQ because of a sudden and fairly constant flow of upstream data that was unusual from that machine, and finding the account & processes involved was easy. As well as installing something to run SSH scans (presumably for further propagation) and running what looked like a crypto-miner, it seemed to be forwarding HTTP(S) requests in a manner that suggested the machine had become part of a “residential proxy” network or similar. Maybe if it hadn't been so greedy I wouldn't have noticed so soon (it hadn't been able to, or hand't tried to, cover its traces, so I found the time of installation very easily as the account otherwise had no SSH activity).
Luckily there were no open root escalation attacks at the time (at least that it knew about) so I only needed to pave that account to get rid of everything, but combined with one of the LPE attacks that have been around over the years it could have caused me much more of a headache.
- Install Proxies, DDoS Agents, Bitcoin mining, proxy to SMTP servers, etc...
- If anything looks interesting on their console they will log in and poke around. The order of these events depends on the sophistication of the bot script. Most are very simple.
If you the target look like you have money they may install ransomware and encrypt some of your files. Now I want to watch the Beekeeper again as corny as it was, also a fun movie.
- Installing a cryptominer or persistence tool
- Sending spam (smtp)
- Using pre-obtained credentials to log into various ecommerce/social media sites
This is a terrible idea because it's blacklist-based security. Places like GitHub have their own ssh server that only runs the git server and nothing else.
https://www.man7.org/linux/man-pages/man8/nologin.8.html
It does not stop you from, say, logging in to SSH and then starting a port forward. Or running a command in a way that bypasses the login shell. ssh will always pass it to your login shell but other ways can be vulnerable.
It is a common username (see: https://en.wikipedia.org/wiki/Toor_(Unix) ), the machine I am typing this on has it.
If we are going to be clever we should follow the statistics and go for 12 that where not on the toplist!!
12 - Rank 318
21 - Rank 523
I'm surprised that '12' is so low on the list.