Re: [PATCH] net: bluetooth: Fix null pointer dereference in hci_event_packet()

2020-10-01 Thread Anmol Karn
On Thu, Oct 01, 2020 at 09:06:42AM +0200, Marcel Holtmann wrote: > Hi Anmol, > > > AMP_MGR is getting derefernced in hci_phy_link_complete_evt(), when called > > from hci_event_packet() and there is a possibility, that hcon->amp_mgr may > > not be found when accessing after initialization of hco

Re: [PATCH] net: bluetooth: Fix null pointer dereference in hci_event_packet()

2020-10-01 Thread Marcel Holtmann
Hi Anmol, > AMP_MGR is getting derefernced in hci_phy_link_complete_evt(), when called > from hci_event_packet() and there is a possibility, that hcon->amp_mgr may > not be found when accessing after initialization of hcon. > > - net/bluetooth/hci_event.c:4945 > The bug seems to get triggered i

[PATCH] net: bluetooth: Fix null pointer dereference in hci_event_packet()

2020-09-30 Thread Anmol Karn
AMP_MGR is getting derefernced in hci_phy_link_complete_evt(), when called from hci_event_packet() and there is a possibility, that hcon->amp_mgr may not be found when accessing after initialization of hcon. - net/bluetooth/hci_event.c:4945 The bug seems to get triggered in this line: bredr_hco

[Linux-kernel-mentees] [PATCH] net: bluetooth: Fix null pointer dereference in hci_event_packet()

2020-09-29 Thread Anmol Karn
AMP_MGR is getting derefernced in hci_phy_link_complete_evt(), when called from hci_event_packet() and there is a possibility, that hcon->amp_mgr may not be found when accessing after initialization of hcon. - net/bluetooth/hci_event.c:4945 The bug seems to get triggered in this line: bredr_hco

Re: [Linux-kernel-mentees] [PATCH] net: bluetooth: Fix null pointer dereference in hci_event_packet()

2020-09-14 Thread Anmol Karn
Hello Sir, > > I have looked into the Bisected logs and the problem occurs from this > > commit: > > > > 941992d29447 ("ethernet: amd: use IS_ENABLED() instead of checking for > > built-in or module") > > > > That's just the patch which made the code testable by syzbot. It didn't > introduc

Re: [Linux-kernel-mentees] [PATCH] net: bluetooth: Fix null pointer dereference in hci_event_packet()

2020-09-14 Thread Dan Carpenter
On Sat, Sep 12, 2020 at 02:40:28PM +0530, Anmol Karn wrote: > On Thu, Sep 10, 2020 at 01:49:18PM +0300, Dan Carpenter wrote: > > On Thu, Sep 10, 2020 at 10:04:24AM +0530, Anmol Karn wrote: > > > Prevent hci_phy_link_complete_evt() from dereferencing 'hcon->amp_mgr' > > > as NULL. Fix it by adding p

Re: [Linux-kernel-mentees] [PATCH] net: bluetooth: Fix null pointer dereference in hci_event_packet()

2020-09-12 Thread Anmol Karn
On Thu, Sep 10, 2020 at 01:49:18PM +0300, Dan Carpenter wrote: > On Thu, Sep 10, 2020 at 10:04:24AM +0530, Anmol Karn wrote: > > Prevent hci_phy_link_complete_evt() from dereferencing 'hcon->amp_mgr' > > as NULL. Fix it by adding pointer check for it. > > > > Reported-and-tested-by: > > syzbot+0b

Re: [Linux-kernel-mentees] [PATCH] net: bluetooth: Fix null pointer dereference in hci_event_packet()

2020-09-10 Thread Anmol Karn
On Thu, Sep 10, 2020 at 01:49:18PM +0300, Dan Carpenter wrote: > On Thu, Sep 10, 2020 at 10:04:24AM +0530, Anmol Karn wrote: > > Prevent hci_phy_link_complete_evt() from dereferencing 'hcon->amp_mgr' > > as NULL. Fix it by adding pointer check for it. > > > > Reported-and-tested-by: > > syzbot+0b

Re: [Linux-kernel-mentees] [PATCH] net: bluetooth: Fix null pointer dereference in hci_event_packet()

2020-09-10 Thread Dan Carpenter
On Thu, Sep 10, 2020 at 10:04:24AM +0530, Anmol Karn wrote: > Prevent hci_phy_link_complete_evt() from dereferencing 'hcon->amp_mgr' > as NULL. Fix it by adding pointer check for it. > > Reported-and-tested-by: syzbot+0bef568258653cff2...@syzkaller.appspotmail.com > Link: https://syzkaller.appspot

Re: [PATCH] net: bluetooth: Fix null pointer dereference in hci_event_packet()

2020-09-09 Thread Anmol Karn
On Wed, Sep 09, 2020 at 10:06:59PM -0700, Eric Biggers wrote: > On Thu, Sep 10, 2020 at 10:04:24AM +0530, Anmol Karn wrote: > > Prevent hci_phy_link_complete_evt() from dereferencing 'hcon->amp_mgr' > > as NULL. Fix it by adding pointer check for it. > > > > Reported-and-tested-by: > > syzbot+0be

Re: [PATCH] net: bluetooth: Fix null pointer dereference in hci_event_packet()

2020-09-09 Thread Eric Biggers
On Thu, Sep 10, 2020 at 10:04:24AM +0530, Anmol Karn wrote: > Prevent hci_phy_link_complete_evt() from dereferencing 'hcon->amp_mgr' > as NULL. Fix it by adding pointer check for it. > > Reported-and-tested-by: syzbot+0bef568258653cff2...@syzkaller.appspotmail.com > Link: https://syzkaller.appspot

[Linux-kernel-mentees] [PATCH] net: bluetooth: Fix null pointer dereference in hci_event_packet()

2020-09-09 Thread Anmol Karn
Prevent hci_phy_link_complete_evt() from dereferencing 'hcon->amp_mgr' as NULL. Fix it by adding pointer check for it. Reported-and-tested-by: syzbot+0bef568258653cff2...@syzkaller.appspotmail.com Link: https://syzkaller.appspot.com/bug?extid=0bef568258653cff272f Signed-off-by: Anmol Karn --- ne