News for hackers. Stuff that matters.
Re:Protecting sshd using spiped by jcr on Thursday August 30, 2012 @07:22AM (#4454022)
Colin, I've always thought of running SSH on some other port as the equivalent of painting your front door camouflage with the hope attackers might overlook it -- in other words, pointless. It might stop some of the "log spam" from dumb brute force attacks on port 22, but if a port scan was done to find the sshd listening port (i.e. a smart attacker), then you still get attacked and log spammed. As far as I know, this issue is best handled by pf.

I'm probably missing something obvious, but I don't understand how spipe/spiped on another port fixes (or helps) the brute force problem?

Re:Protecting sshd using spiped by cperciva on Thursday August 30, 2012 @07:27AM (#4454030)
People can connect to spiped, but nothing will go through to sshd unless they can complete the handshake (which requires an unfeasible amount of work unless the person connecting holds the spiped secret).
Re:Protecting sshd using spiped by jcr on Thursday August 30, 2012 @08:03AM (#4454135)
Interesting. I'll check it out. Thanks!

I've always wanted something like spamd(8) for ssh, so everyone who normally blocks inbound port 22 can work together to thwart the brute force attacks by providing a honeypot/sandtrap/tarpit for the attack scripts to waste all of their time and resources.

Re:Protecting sshd using spiped by gizzlon on Thursday August 30, 2012 @08:49AM (#4454322)
"in other words, pointless. It might stop some of the "log spam".."

You kind-of contradicted yourself in four words there.. Afaik, it stops the most common "attacks", the automated drive-by password-guessing attacks. Far from pointless.

Re:Protecting sshd using spiped by jcr on Thursday August 30, 2012 @09:20AM (#4454443)
I can see your point but you're not looking at the problem realistically; dumb attack tools get smarter over time. Let's say a dumb attack tool tries to access the root account over ssh on port 22. If enough people disable root ssh access or stop running ssh on port 22, then you should expect the attack tools to evolve (and yes, they have) to trying other accounts and other ports. The end result is your logs still get filled with crap. If your goal is to prevent your logs from being filled with crap, then changing ports won't solve the problem.

Personally, I don't know of a working solution to prevent ssh brute force attacks from filling up our logs with crap, but something like spamd(8) for sshd might make the attackers give up (or at least learn to leave the people running it alone).

http://www.openbsd.org/spamd/

http://www.openbsd.org/cgi-bin/man.cgi?query=spamd&sekti...

http://www.openbsd.org/cgi-bin/man.cgi?query=spamd-setup&...

The goal of spamd(8) is making it painful, slow, and expensive for spammers while keeping mail services running. It seems Colin is headed in a vaguely similar direction with spipe/spiped albeit without the intentionally sadistic tar-pitting and stuttering of spamd(8).

Re:Protecting sshd using spiped by gizzlon on Thursday August 30, 2012 @09:54AM (#4454625)
yup, something like spamd for ssh could be cool..

But evolving to crack other usernames and other ports is not so easy, and there's not even any incentive to do that yet.

"If your goal is to prevent your logs from being filled with crap, then changing ports won't solve the problem"

..Looking at my logs..

Yes, it did actually :)

(edit: typo)

Re:Protecting sshd using spiped by jcr on Thursday August 30, 2012 @10:30AM (#4454800)
I'm glad using an alternate port still works for you. On my home network, I lost my patience with the attacks a while ago and simply prevented sshd binding to the external interface of my firewall(s). Since I don't need external access to my home network, it was the easy way out.

Some friends of mine run tunnelr.com where they run sshd on multiple ports, and they get hammered by attacks on a regular basis. Since they are a VPN service with tons of bandwidth, they're a prime target, and they get attacked on any port where sshd is running. It's a mess, and the approach that's working for you, doesn't work for them (and others I know).

Just out of curiosity, and without naming any (domain) names, would you consider the systems where you're running on a nonstandard port to be "popular" or "high value" or "interesting" targets for attackers? (i.e. subjected to targeted attacks rather than just the typical bulk/blind/dumb attacks)?

Re:Protecting sshd using spiped by gizzlon on Friday August 31, 2012 @03:57AM (#4458749)
"Just out of curiosity, and without naming any (domain) names, would you consider the systems where you're running on a nonstandard port to be "popular" or "high value" or "interesting" targets for attackers? (i.e. subjected to targeted attacks rather than just the typical bulk/blind/dumb attacks)?"

No, not at all.

But remember what we are talking about here. You said moving ports is "pointless", and I argued that's it's not because it stops a lot of drive-by attacks. Instead of simply acknowledging this, you spent a lot of words arguing a straw-man.

Re:Protecting sshd using spiped by jcr on Friday August 31, 2012 @11:41AM (#4460145)
Actually, I didn't intend to be argumentative, contradict you, use straw man nonsense, or try to convince you of anything. I'm sorry if it came across that way.

What I'd like to do is just grasp the reason for the discrepancy between your experience and my own (and folks I know)? Obviously, changing ports works for you, and not for me, so I'm trying to figure out why. Maybe it's the type of sites you run, how you host them (racked, cloud, home, ...), upstream/provider filtering, where you're located, or something else?

Re:Protecting sshd using spiped by gizzlon on Friday August 31, 2012 @12:18PM (#4460322)
My guess is just that my sites fly under the radar because they are unimportant, have little traffic etc..

But if people finds you random (not <1024) ssh port, they probably scanned all of you ports? Which seems drastic. Last time I checked, a few years ago, it was not normal to scan all the ports on a large block of IPs. Maybe that changed, but I have never seen that on the few machines and networks I can check.

Anyway, my point is that targeted attacks is a another ballgame, but that does not make it pointless to protect against the dumb, automated attacks.