• keisatsu@infosec.pub
    link
    fedilink
    English
    arrow-up
    21
    ·
    9 hours ago

    Adding a user to the docker group is equivalent with granting it passwordless root privileges, never do that unless you know precisely why and understand the risks involved.

    On the positive side, forbidding password-based auth, installing and using a firewall and locking down the root account is good advice

    • MalReynolds@piefed.social
      link
      fedilink
      English
      arrow-up
      3
      ·
      4 hours ago

      Getting whatever you can (likely most, or all) into rootless podman, preferably with SELinux is worthwhile. Docker is a security nightmare.

      • galaxy_nova@lemmy.world
        link
        fedilink
        English
        arrow-up
        1
        ·
        2 hours ago

        I have a whole bunch of docker compose declared containers running on my server how much of an investment do you think it’d be to podman? I don’t like how insecure docker is but it seems like a pain to move.

        • MalReynolds@piefed.social
          link
          fedilink
          English
          arrow-up
          2
          ·
          edit-2
          2 minutes ago

          Not going to lie, there is pain, but maintenance is much nicer. I’ve gotten to the point where I can just convert docker-compose to quadlet by eye, the syntax is familiar if you know systemd.

          https://github.com/containers/podlet can be pointed at a docker-compose and spits out quadlets. It’s been a while but last I used it, it would get it right 80%+ of the time on complex things and get you 85%+ there when it failed. There’s also podman-compose which is a crutch but can establish compatibility. /usr/libexec/podman/quadlet -dryrun -user is a useful diagnostic when conversions break.

        • bitfucker@programming.dev
          link
          fedilink
          arrow-up
          1
          ·
          18 minutes ago

          Honestly the issue is docker was never designed to be a security boundary. Docker is always from the beginning a way to deploy application without conflicting shared library requirements. Looser than isolation of VM, but also not as hard as every other existing solution at that time (dedicated chroot, static linking, appimage, flatpak)

  • lntl@lemmy.sdf.org
    link
    fedilink
    arrow-up
    1
    ·
    5 hours ago

    I would add changing the SSH port to one that isn’t 22. This isn’t any more secure, but does tamp down on automated scanner traffic.