Re: [PATCH] 9p: prevent read overrun in protocol dump tracepoint

2023-12-01 Thread asmadeus
asmad...@codewreck.org wrote on Sat, Dec 02, 2023 at 01:35:18PM +0900: > > diff --git a/include/trace/events/9p.h b/include/trace/events/9p.h > > index 4dfa6d7f83ba..8690a7086252 100644 > > --- a/include/trace/events/9p.h > > +++ b/include/trace/events/9p.h > > @@ -185,7 +185,8 @@

Re: ARM Ftrace Function Graph Fails With UNWINDER_FRAME_POINTER

2023-12-01 Thread Ard Biesheuvel
On Fri, 1 Dec 2023 at 23:59, Justin Chen wrote: > > > > On 12/1/23 10:07 AM, Steven Rostedt wrote: > > On Fri, 1 Dec 2023 09:25:59 -0800 > > Justin Chen wrote: > > > >>> It appears the sub instruction at 0x6dd0 correctly accounts for the > >>> extra 8 bytes, so the frame pointer is valid. So it

Re: [PATCH] 9p: prevent read overrun in protocol dump tracepoint

2023-12-01 Thread asmadeus
JP Kobryn wrote on Fri, Dec 01, 2023 at 07:04:10PM -0800: > An out of bounds read can occur within the tracepoint 9p_protocol_dump(). > In the fast assign, there is a memcpy that uses a constant size of 32 > (macro definition as P9_PROTO_DUMP_SZ). When the copy is invoked, the > source buffer is

[PATCH] 9p: prevent read overrun in protocol dump tracepoint

2023-12-01 Thread JP Kobryn
An out of bounds read can occur within the tracepoint 9p_protocol_dump(). In the fast assign, there is a memcpy that uses a constant size of 32 (macro definition as P9_PROTO_DUMP_SZ). When the copy is invoked, the source buffer is not guaranteed match this size. It was found that in some cases the

Re: ARM Ftrace Function Graph Fails With UNWINDER_FRAME_POINTER

2023-12-01 Thread Justin Chen
On 12/1/23 10:07 AM, Steven Rostedt wrote: On Fri, 1 Dec 2023 09:25:59 -0800 Justin Chen wrote: It appears the sub instruction at 0x6dd0 correctly accounts for the extra 8 bytes, so the frame pointer is valid. So it is our assumption that there are no gaps between the stack frames is

Re: ARM Ftrace Function Graph Fails With UNWINDER_FRAME_POINTER

2023-12-01 Thread Russell King (Oracle)
On Fri, Dec 01, 2023 at 10:12:48AM +0100, Ard Biesheuvel wrote: > It appears the sub instruction at 0x6dd0 correctly accounts for the > extra 8 bytes, so the frame pointer is valid. So it is our assumption > that there are no gaps between the stack frames is invalid. > > Could you try the

Re: ARM Ftrace Function Graph Fails With UNWINDER_FRAME_POINTER

2023-12-01 Thread Steven Rostedt
On Fri, 1 Dec 2023 09:25:59 -0800 Justin Chen wrote: > > It appears the sub instruction at 0x6dd0 correctly accounts for the > > extra 8 bytes, so the frame pointer is valid. So it is our assumption > > that there are no gaps between the stack frames is invalid. > > Thanks for the assistance.

Re: ARM Ftrace Function Graph Fails With UNWINDER_FRAME_POINTER

2023-12-01 Thread Justin Chen
On 12/1/2023 1:12 AM, Ard Biesheuvel wrote: On Fri, 1 Dec 2023 at 00:48, Justin Chen wrote: Hello, Ran into an odd bug that I am unsure what the solution is. Tested a few kernels versions and they all fail the same. FUNCTION_GRAPH_FP_TEST was enabled with 953f534a7ed6 ("ARM: ftrace:

Re: ARM Ftrace Function Graph Fails With UNWINDER_FRAME_POINTER

2023-12-01 Thread Ard Biesheuvel
On Fri, 1 Dec 2023 at 00:48, Justin Chen wrote: > > Hello, > > Ran into an odd bug that I am unsure what the solution is. Tested a few > kernels versions and they all fail the same. > > FUNCTION_GRAPH_FP_TEST was enabled with 953f534a7ed6 ("ARM: ftrace: > enable HAVE_FUNCTION_GRAPH_FP_TEST").