Re: Running ssh on unreserved ports



Hi,

I'd like to move it to a higher port to avoid the normal doorknob
rattling that occurs with ssh running on a public server.
You can do this from iptables:

1. block port 22 in iptables

2. Add the following rule:
  iptables -t nat -A PREROUTING -p tcp -m tcp --dport 2345 -m state --state NEW -j REDIRECT --to-ports 22

Ah, great trick. Definitely have to try that.

Thanks,
Alex
--
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines



Relevant Pages

  • Re: Preventing abuse of CGI & PHP by spammers
    ... In fact, BTDT, wrote the tarpit:) ... Best trick I found - use iptables -j REDIRECT to divert incoming packets ...
    (comp.os.linux.security)
  • Re: Block port 80 allow port 110&25
    ... you append will be given last number. ... iptables -I instead iptables -A ... block port 80 but allow port 110 and 25 in my lan ... Redhat Channel Partner and Training Partner ...
    (RedHat)
  • Re: [fw-wiz] Linux Firewalls
    ... Actually, IPtables is fairly straightforward, it was taught to me in 20 minutes. ... The trick will be editing the files: if you're not good at vi, and pico isn't installed, your best bet would to be to edit on the desktop, in a GUI environment like KDE. ... the FIRST part of making a Linux Firewall is locking down the OS. ...
    (Firewall-Wizards)
  • Port scan blocking with ipfw
    ... I was wondering if there's a way to block port scans in ipfw. ... something similar to the psd module for iptables? ...
    (freebsd-stable)
  • Re: software time lock and web access control
    ... I know maybe a combintion of IPTABLES and probably SQUID should do the ... You can probably just use iptables and a cron job. ...
    (Fedora)