Something tells me I need to update my security…

  • Zetaphor@zemmy.cc
    link
    fedilink
    English
    arrow-up
    8
    ·
    1 year ago

    How many of you actually disable root and password based login, change the default SSH port, and setup fail2ban?

      • jason@sh.itjust.works
        link
        fedilink
        English
        arrow-up
        2
        ·
        1 year ago

        This is 100% the way to go. I spun up a new server for a public-facing site on my VPS and I wondered if I really needed fail2ban. Within ten minutes of setting it up it had already blocked four people.

        Don’t open port 22 if you can help it. Use it on your local network and VPN in if you need to use it offsite.

    • sudneo@lemmy.world
      link
      fedilink
      English
      arrow-up
      1
      ·
      1 year ago

      That is part of my bootstrap ansible playbook, which in addition to create user, setting key, etc., will definitely disable root and password login, enable max tries and setup f2b. I am not necessarily afraid of exposing ssh to the internet (it is a service designed for it), but I drastically reduce the risk this way. I am thinking of also changing port to simply get less logs.

      • Zetaphor@zemmy.cc
        link
        fedilink
        English
        arrow-up
        3
        ·
        1 year ago

        There’s no reason to allow root login, it’s asking for trouble. Password based login is even worse. Changing the SSH port just makes it harder for the drive-by bots trying the whole IPv4 range