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] [day] [month] [year] [list]
Date:	Mon, 21 Jul 2008 07:27:48 +0100
From:	Al Viro <viro@...IV.linux.org.uk>
To:	Jens Axboe <jens.axboe@...cle.com>
Cc:	pjones@...hat.com, FUJITA Tomonori <fujita.tomonori@....ntt.co.jp>,
	linux-kernel@...r.kernel.org
Subject: Re: [RFC] breakage in bsg

On Sun, Jul 20, 2008 at 05:34:06PM +0100, Al Viro wrote:

> 	* cmd_filter thing is broken as well (we have no access to
> gendisk in question and there's a lot of obvious issues when you have
> several openers).
> 
> #2 and part of #3 are fixable, but I really don't see what to do with #1.
> If nothing else, it's absolutely incompatible with cmd_filter, even if you
> leave aside the issue with non-IDE/non-SCSI drivers.

Actually, cmd_filter changeset breaks all users of blk_verify_command().
It expects that struct file passed to will be that of a block device:
        inode = file->f_dentry->d_inode;
        if (!inode)
                return -EINVAL;

        disk = inode->i_bdev->bd_disk;

        return blk_cmd_filter_verify_command(&disk->cmd_filter,
                                                 cmd, &file->f_mode);

Unfortunately, all of those can get struct file of *character* device, with
obvious results.

The minimal fix is to pass disk / mode explicitly.  I'll post the patch,
but that still leaves bsg broken.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ