All of lore.kernel.org
 help / color / mirror / Atom feed
From: Aymen T <atijari00@gmail.com>
To: stable@vger.kernel.org
Cc: jack@suse.cz
Subject: [6.1.y] udf: VAT inode size checks
Date: Sat, 21 Nov 2026 19:16:55 +0100	[thread overview]
Message-ID: <aac8e196-3fbb-4445-b154-5b9129dde41e@gmail.com> (raw)

Hi,

Please consider these two for 6.1.y:

  5163e6ee1ea7 ("udf: validate VAT inode size for old VAT format")
  49f771d14578 ("udf: validate vat20->lengthHeader and VAT inode size in udf_load_vat()")

6.1.192 still computes the old-format VAT entry count without checking
the inode size:

        map->s_type_specific.s_virtual.s_num_entries =
                (sbi->s_vat_inode->i_size - 36) >> 2;

so a VAT inode smaller than 36 bytes gives a huge s_num_entries, and
udf_get_pblock_virt15() then reads a VAT entry far past the VAT data.
On 6.1.180 in QEMU, with a crafted image on a USB stick, that value
became the LBA of the next read.

5163e6ee1ea7 applies cleanly to 6.1.192. 49f771d14578 needs fuzz on
its first hunk, because 6.1.y doesn't have the udf_block_map() error
handling that surrounds it in mainline; the resulting change is the
same two checks. I can send it as a backport if that's easier.

Thanks,
Aymen

             reply	other threads:[~2026-11-21 18:16 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-21 18:16 Aymen T [this message]
2026-11-22  3:38 ` [6.1.y] udf: VAT inode size checks Sasha Levin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=aac8e196-3fbb-4445-b154-5b9129dde41e@gmail.com \
    --to=atijari00@gmail.com \
    --cc=jack@suse.cz \
    --cc=stable@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.