qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [Bug 1703147] [NEW] Xfer:features:read truncating xml sent to gdb frontends
@ 2017-07-08 21:19 Duane Voth
  2017-07-08 21:44 ` Peter Maydell
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: Duane Voth @ 2017-07-08 21:19 UTC (permalink / raw)
  To: qemu-devel

Public bug reported:

Around line 1326 in gdbstub.c:

            if (len > (MAX_PACKET_LENGTH - 5) / 2)
                len = (MAX_PACKET_LENGTH - 5) / 2;

is truncating processor reg description xml files longer than 2045
bytes.  Deleting these lines works for my immediate need, but they seem
to be trying to fix some buffer overrun condition so I won't offer a
patch until we understand their purpose.

** Affects: qemu
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1703147

Title:
  Xfer:features:read truncating xml sent to gdb frontends

Status in QEMU:
  New

Bug description:
  Around line 1326 in gdbstub.c:

              if (len > (MAX_PACKET_LENGTH - 5) / 2)
                  len = (MAX_PACKET_LENGTH - 5) / 2;

  is truncating processor reg description xml files longer than 2045
  bytes.  Deleting these lines works for my immediate need, but they
  seem to be trying to fix some buffer overrun condition so I won't
  offer a patch until we understand their purpose.

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1703147/+subscriptions

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [Qemu-devel] [Bug 1703147] [NEW] Xfer:features:read truncating xml sent to gdb frontends
  2017-07-08 21:19 [Qemu-devel] [Bug 1703147] [NEW] Xfer:features:read truncating xml sent to gdb frontends Duane Voth
@ 2017-07-08 21:44 ` Peter Maydell
  2021-05-02  5:41 ` [Bug 1703147] " Thomas Huth
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: Peter Maydell @ 2017-07-08 21:44 UTC (permalink / raw)
  To: Bug 1703147; +Cc: QEMU Developers

On 8 July 2017 at 22:19, Duane Voth <duanev@gmail.com> wrote:
> Around line 1326 in gdbstub.c:
>
>             if (len > (MAX_PACKET_LENGTH - 5) / 2)
>                 len = (MAX_PACKET_LENGTH - 5) / 2;
>
> is truncating processor reg description xml files longer than 2045
> bytes.  Deleting these lines works for my immediate need, but they seem
> to be trying to fix some buffer overrun condition so I won't offer a
> patch until we understand their purpose.

Those lines prevent the packet we're constructing overrunning
the buf[] array (in the worst case the packet encoding could
use 2 bytes of buffer for every byte of payload). It's probably
working for you without them because (a) the XML payload doesn't
come near the worst-case and (b) buf[] is followed on the stack
by mem_buf[] which happens to be unused here so overrunning into
it has no visible harmful effects.

Truncating the XML is clearly not what we want though so we
should do something more intelligent...

thanks
-- PMM

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug 1703147] Re: Xfer:features:read truncating xml sent to gdb frontends
  2017-07-08 21:19 [Qemu-devel] [Bug 1703147] [NEW] Xfer:features:read truncating xml sent to gdb frontends Duane Voth
  2017-07-08 21:44 ` Peter Maydell
@ 2021-05-02  5:41 ` Thomas Huth
  2021-07-02  4:17 ` Launchpad Bug Tracker
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: Thomas Huth @ 2021-05-02  5:41 UTC (permalink / raw)
  To: qemu-devel

The QEMU project is currently considering to move its bug tracking to
another system. For this we need to know which bugs are still valid
and which could be closed already. Thus we are setting older bugs to
"Incomplete" now.

If you still think this bug report here is valid, then please switch
the state back to "New" within the next 60 days, otherwise this report
will be marked as "Expired". Or please mark it as "Fix Released" if
the problem has been solved with a newer version of QEMU already.

Thank you and sorry for the inconvenience.


** Changed in: qemu
       Status: New => Incomplete

-- 
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1703147

Title:
  Xfer:features:read truncating xml sent to gdb frontends

Status in QEMU:
  Incomplete

Bug description:
  Around line 1326 in gdbstub.c:

              if (len > (MAX_PACKET_LENGTH - 5) / 2)
                  len = (MAX_PACKET_LENGTH - 5) / 2;

  is truncating processor reg description xml files longer than 2045
  bytes.  Deleting these lines works for my immediate need, but they
  seem to be trying to fix some buffer overrun condition so I won't
  offer a patch until we understand their purpose.

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1703147/+subscriptions


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug 1703147] Re: Xfer:features:read truncating xml sent to gdb frontends
  2017-07-08 21:19 [Qemu-devel] [Bug 1703147] [NEW] Xfer:features:read truncating xml sent to gdb frontends Duane Voth
  2017-07-08 21:44 ` Peter Maydell
  2021-05-02  5:41 ` [Bug 1703147] " Thomas Huth
@ 2021-07-02  4:17 ` Launchpad Bug Tracker
  2021-07-02  4:48 ` Duane Voth
  2021-07-02  6:49 ` Thomas Huth
  4 siblings, 0 replies; 6+ messages in thread
From: Launchpad Bug Tracker @ 2021-07-02  4:17 UTC (permalink / raw)
  To: qemu-devel

[Expired for QEMU because there has been no activity for 60 days.]

** Changed in: qemu
       Status: Incomplete => Expired

-- 
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1703147

Title:
  Xfer:features:read truncating xml sent to gdb frontends

Status in QEMU:
  Expired

Bug description:
  Around line 1326 in gdbstub.c:

              if (len > (MAX_PACKET_LENGTH - 5) / 2)
                  len = (MAX_PACKET_LENGTH - 5) / 2;

  is truncating processor reg description xml files longer than 2045
  bytes.  Deleting these lines works for my immediate need, but they
  seem to be trying to fix some buffer overrun condition so I won't
  offer a patch until we understand their purpose.

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1703147/+subscriptions


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug 1703147] Re: Xfer:features:read truncating xml sent to gdb frontends
  2017-07-08 21:19 [Qemu-devel] [Bug 1703147] [NEW] Xfer:features:read truncating xml sent to gdb frontends Duane Voth
                   ` (2 preceding siblings ...)
  2021-07-02  4:17 ` Launchpad Bug Tracker
@ 2021-07-02  4:48 ` Duane Voth
  2021-07-02  6:49 ` Thomas Huth
  4 siblings, 0 replies; 6+ messages in thread
From: Duane Voth @ 2021-07-02  4:48 UTC (permalink / raw)
  To: qemu-devel

Problematic code now around lines 2221 (in handle_query_xfer_features)
... lol I'm the only one impacted ... all the large register set cpus
can be affected.

** Changed in: qemu
       Status: Expired => New

-- 
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1703147

Title:
  Xfer:features:read truncating xml sent to gdb frontends

Status in QEMU:
  New

Bug description:
  Around line 1326 in gdbstub.c:

              if (len > (MAX_PACKET_LENGTH - 5) / 2)
                  len = (MAX_PACKET_LENGTH - 5) / 2;

  is truncating processor reg description xml files longer than 2045
  bytes.  Deleting these lines works for my immediate need, but they
  seem to be trying to fix some buffer overrun condition so I won't
  offer a patch until we understand their purpose.

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1703147/+subscriptions


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug 1703147] Re: Xfer:features:read truncating xml sent to gdb frontends
  2017-07-08 21:19 [Qemu-devel] [Bug 1703147] [NEW] Xfer:features:read truncating xml sent to gdb frontends Duane Voth
                   ` (3 preceding siblings ...)
  2021-07-02  4:48 ` Duane Voth
@ 2021-07-02  6:49 ` Thomas Huth
  4 siblings, 0 replies; 6+ messages in thread
From: Thomas Huth @ 2021-07-02  6:49 UTC (permalink / raw)
  To: qemu-devel

This is an automated cleanup. This bug report has been moved to QEMU's
new bug tracker on gitlab.com and thus gets marked as 'expired' now.
Please continue with the discussion here:

 https://gitlab.com/qemu-project/qemu/-/issues/458


** Changed in: qemu
       Status: New => Expired

** Bug watch added: gitlab.com/qemu-project/qemu/-/issues #458
   https://gitlab.com/qemu-project/qemu/-/issues/458

-- 
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1703147

Title:
  Xfer:features:read truncating xml sent to gdb frontends

Status in QEMU:
  Expired

Bug description:
  Around line 1326 in gdbstub.c:

              if (len > (MAX_PACKET_LENGTH - 5) / 2)
                  len = (MAX_PACKET_LENGTH - 5) / 2;

  is truncating processor reg description xml files longer than 2045
  bytes.  Deleting these lines works for my immediate need, but they
  seem to be trying to fix some buffer overrun condition so I won't
  offer a patch until we understand their purpose.

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1703147/+subscriptions


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2021-07-02  6:57 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-07-08 21:19 [Qemu-devel] [Bug 1703147] [NEW] Xfer:features:read truncating xml sent to gdb frontends Duane Voth
2017-07-08 21:44 ` Peter Maydell
2021-05-02  5:41 ` [Bug 1703147] " Thomas Huth
2021-07-02  4:17 ` Launchpad Bug Tracker
2021-07-02  4:48 ` Duane Voth
2021-07-02  6:49 ` Thomas Huth

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).