Re: Re: [PATCH] Bluetooth: Fix potential NULL dereference

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Marcel,

>> addr can be NULL and it should not be dereferenced before NULL checking.
>> 
>> Signed-off-by: Jaganath Kanakkassery <jaganath.k@xxxxxxxxxxx>
>> ---
>
>if we start changing things here, then we better change the code into something that all the other socket handling code is doing anyway>y. So do the min comparison and copy the data into a local copy of the sockaddr_rc.
>
>And on a side note, I wonder if addr can actually be NULL. It might be interesting to check the generic socket code if this really can happe>n if you provide no address structure to the bind() system call or if this gets filtered out by the core socket code.

I checked generic socket code and it looks like addr will never be NULL when user space calls bind.
But this can be called from kernel_bind() also which I think will never be called for RFCOMM.
So this patch is not required? 

Thanks,
Jaganathÿôèº{.nÇ+‰·Ÿ®‰­†+%ŠËÿ±éݶ¥Šwÿº{.nÇ+‰·¥Š{±ý¹nzÚ(¶âžØ^n‡r¡ö¦zË?ëh™¨è­Ú&£ûàz¿äz¹Þ—ú+€Ê+zf£¢·hšˆ§~†­†Ûiÿÿï?êÿ‘êçz_è®æj:+v‰¨þ)ߣøm





[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux