lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAFLxGvxH=4rHWu-44LSuWaGA_OB0FU0Eq4fedVTj3tf2D3NgYQ@mail.gmail.com>
Date: Tue, 8 Apr 2025 12:11:36 +0200
From: Richard Weinberger <richard.weinberger@...il.com>
To: "Darrick J. Wong" <djwong@...nel.org>
Cc: Christian Brauner <brauner@...nel.org>, Cengiz Can <cengiz.can@...onical.com>, 
	Attila Szasz <szasza.contact@...il.com>, Greg KH <gregkh@...uxfoundation.org>, 
	Salvatore Bonaccorso <carnil@...ian.org>, linux-fsdevel@...r.kernel.org, 
	linux-kernel@...r.kernel.org, lvc-patches@...uxtesting.org, 
	dutyrok@...linux.org, syzbot+5f3a973ed3dfb85a6683@...kaller.appspotmail.com, 
	stable@...r.kernel.org, Alexander Viro <viro@...iv.linux.org.uk>
Subject: Re: [PATCH] hfs/hfsplus: fix slab-out-of-bounds in hfs_bnode_read_key

On Mon, Apr 7, 2025 at 9:08 PM Darrick J. Wong <djwong@...nel.org> wrote:
> It's also the default policy on Debian 12 and RHEL9 that if you're
> logged into the GUI, any program can run:
>
> $ truncate -s 3g /tmp/a
> $ mkfs.hfs /tmp/a
> $ <write evil stuff on /tmp/a>
> $ udisksctl loop-setup -f /tmp/a
> $ udisksctl mount -b /dev/loopX
>
> and the user never sees a prompt.  GNOME and KDE both display a
> notification when the mount finishes, but by then it could be too late.
> Someone should file a CVE against them too.

At least on SUSE orphaned and other problematic filesystem kernel modules
are blacklisted. I wonder why other distros didn't follow this approach.

> You can tighten this up by doing this:
>
> # cat > /usr/share/polkit-1/rules.d/always-ask-mount.rules << ENDL
> // don't allow mounting, reformatting, or loopdev creation without asking
> polkit.addRule(function(action, subject) {
>         if ((action.id == "org.freedesktop.udisks2.loop-setup" ||
>              action.id == "org.freedesktop.udisks2.filesystem-mount" ||
>              action.id == "org.freedesktop.udisks2.modify-device") &&
>             subject.local == true) {
>                 return polkit.Result.AUTH_ADMIN_KEEP;
>         }
> });
> ENDL

Thanks for sharing this!

> so at least you have to authenticate with an admin account.  We do love
> our footguns, don't we?  At least it doesn't let you do that if you're
> ssh'd in...

IMHO guestmount and other userspace filesystem implementations should
be the default
for such mounts.

//richard

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ