All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Thomas Schmitt" <scdbackup@gmx.net>
To: grub-devel@gnu.org
Cc: lidong.chen@oracle.com, fengtao40@huawei.com, yanan@huawei.com,
	daniel.kiper@oracle.com, lichenca2005@gmail.com,
	development@efficientek.com
Subject: Re: [PATCH v3 0/5] fs/iso9660: Fix out-of-bounds read
Date: Wed, 25 Jan 2023 21:24:00 +0100	[thread overview]
Message-ID: <7405393520348946132@scdbackup.webframe.org> (raw)
In-Reply-To: <Y9FiQYVVJ1VEMve6@tomti.i.net-space.pl>

Hi,

Daniel Kiper wrote:
> Thomas, it would be nice if you could add the broken ISOs images which you
> used for tests to the tests in the GRUB. If you do that please CC Glenn.

Is it wise to have a test which will loop endlessly in case of failure ?
Is there a way to let a test time out ?


Whatever:

After poking in my memory and GRUB's tests directory i came to
tests/util/grub-fs-tester.in which produces its ISOs as needed.
It could be appropriate to create one or both CE loop ISOs there.
But this might become a problem in the future, because the post-production
hacks depend on correct byte addresses in the ISO image.

So it would be better to add one or two canned images:
  897 bytes of http://scdbackup.webframe.org/ce_loop.iso.gz
  904 bytes of http://scdbackup.webframe.org/ce_loop2.iso.gz

Next problem is that these images do not go well with the other tests in
grub-fs-tester.in. I would want to run

  gunzip <ce_loop.iso.gz >ce_loop.iso
  run_grubfstest ls /

in the neighborhood of the xorriso runs and then bail out immediately.
But i don't yet fully understand what the for-loops around the xorriso
runs mean:

  for LOGSECSIZE in $(range "$MINLOGSECSIZE" "$MAXLOGSECSIZE" 1); do
      ...
      for BLKSIZE in $blksizes; do
          ...
          for NDEVICES in $(range "$MINDEVICES" "$MAXDEVICES" 1); do
                  ...
                  x"ziso9660")
                      FSUUID=$(date -u +%Y-%m-%d-%H-%M-%S-00);
                      xorriso ...

So how to bail out properly at this point after e.g.

                  x"iso9660_ce_loop")
                      gunzip <ce_loop.iso.gz >ce_loop.iso
                      run_grubfstest ls /

?

And why do the ls tests in grub-fs-tester.in look like
   run_grubfstest ls -- -la
which i cannot decipher by help of the options[]-list in grub-fstest.c ?


I CC Glenn Washburn already now, in the hope that he can point me to
examples or states that these ISOs should not become part of the tests.
(Crossing fingers for the latter case ... ;-)


Have a nice day :)

Thomas



  reply	other threads:[~2023-01-25 20:25 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-20 19:39 [PATCH v3 0/5] fs/iso9660: Fix out-of-bounds read Lidong Chen
2023-01-20 19:39 ` [PATCH v3 1/5] fs/iso9660: Add check to prevent infinite loop Lidong Chen
2023-02-02 19:35   ` Daniel Kiper
2023-02-02 23:27     ` Lidong Chen
2023-01-20 19:39 ` [PATCH v3 2/5] fs/iso9660: Prevent read past the end of system use area Lidong Chen
2023-01-20 19:39 ` [PATCH v3 3/5] fs/iso9660: Avoid reading past the entry boundary Lidong Chen
2023-01-20 19:39 ` [PATCH v3 4/5] fs/iso9660: Incorrect check for " Lidong Chen
2023-01-20 19:39 ` [PATCH v3 5/5] fs/iso9660: Prevent skipping CE or ST at start of continuation area Lidong Chen
2023-01-21 12:59   ` Thomas Schmitt
2023-01-25 17:09 ` [PATCH v3 0/5] fs/iso9660: Fix out-of-bounds read Daniel Kiper
2023-01-25 20:24   ` Thomas Schmitt [this message]
2023-01-26 22:05     ` Glenn Washburn
2023-01-27 10:56       ` Thomas Schmitt
2023-01-27 21:24         ` Glenn Washburn
2023-01-28  8:19           ` Thomas Schmitt

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=7405393520348946132@scdbackup.webframe.org \
    --to=scdbackup@gmx.net \
    --cc=daniel.kiper@oracle.com \
    --cc=development@efficientek.com \
    --cc=fengtao40@huawei.com \
    --cc=grub-devel@gnu.org \
    --cc=lichenca2005@gmail.com \
    --cc=lidong.chen@oracle.com \
    --cc=yanan@huawei.com \
    /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.