Unverified Commit 02435714 authored by Doron Behar's avatar Doron Behar Committed by GitHub
Browse files

nixos/samba: add mount.cifs +s wrapper (#328901)

parents c02521d9 b33e220f
Loading
Loading
Loading
Loading
+9 −0
Original line number Diff line number Diff line
@@ -239,6 +239,15 @@ in

        security.pam.services.samba = {};
        environment.systemPackages = [ cfg.package ];
        # Like other mount* related commands that need the setuid bit, this is
        # required too.
        security.wrappers."mount.cifs" = {
          program = "mount.cifs";
          source = "${lib.getBin pkgs.cifs-utils}/bin/mount.cifs";
          owner = "root";
          group = "root";
          setuid = true;
        };

        networking.firewall.allowedTCPPorts = mkIf cfg.openFirewall [ 139 445 ];
        networking.firewall.allowedUDPPorts = mkIf cfg.openFirewall [ 137 138 ];