DPsystems / Login-Shield

Your first line of defense against Internet bots, hacks and probes. Login-Shield is a small set of bash scripts that implements an iptables/ipset blocklist of known sources of hack activity. Works great as a compliment with/without fail2ban. Statistics have shown it blocks 90+% of most system probes and attacks on login ports.
Other
37 stars 6 forks source link

New to Login-Shield, need some help #4

Closed aakerbeere closed 3 years ago

aakerbeere commented 3 years ago

Hi I am trying to set up Login-Shield on RPI4B, 64bit OS, Buster, as suggested at "https://github.com/DPsystems/Login-Shield/blob/master/INSTALL". When it comes to "sudo ./blacklist-main-nonUS.sh" i get errors like "./blacklist-main-nonUS.sh: 9: ./blacklist-main-nonUS.sh: [[: not found" and "./blacklist-main-nonUS.sh: 15: ./blacklist-main-nonUS.sh: Syntax error: "(" unexpected (expecting "then")". I don't know if it's me doing something wrong or if this is not suitable at all for my needs. thx for helping.

aakerbeere commented 3 years ago

I use different port

ychaouche commented 3 years ago

Ah, then that's why you don't get anything logged. Add that port to the list (same line). As @DPsystems mentionned, web traffic isn't being monitored, and when I asked about the publicly avaiable services you only mentioned ssh and http. Since http is ruled out, you only have ssh to care about, but you didn't give the correct port number in the config file. Add the relevant port number and re-run.

aakerbeere commented 3 years ago

Done, ssh ok. When preparing i was feared to lock myself out. But actually i understand this only to be the case if my public IP is covered by on of the blacklists in use. thx

ychaouche commented 3 years ago

Which it totally could, yeah. This makes me think this system has to have a whitelist of some sort, which it apparently doesn't. You can add it by hand, but I can't help on this.