diff options
author | Mateusz Jurczyk <[email protected]> | 2017-06-29 14:04:59 +0200 |
---|---|---|
committer | Marcel Holtmann <[email protected]> | 2017-06-29 14:37:57 +0200 |
commit | d2ecfa765dff59145a4ba9c84856e50c4f43c2b2 (patch) | |
tree | 234b4b6a034d7398be70b2ca7dd655de5aad864d /net/lapb/lapb_subr.c | |
parent | 29e2dd0d56ea0d6c4a95c080760e1cc748fb6f14 (diff) |
Bluetooth: Add sockaddr length checks before accessing sa_family in bind and connect handlers
Verify that the caller-provided sockaddr structure is large enough to
contain the sa_family field, before accessing it in bind() and connect()
handlers of the Bluetooth sockets. Since neither syscall enforces a minimum
size of the corresponding memory region, very short sockaddrs (zero or one
byte long) result in operating on uninitialized memory while referencing
sa_family.
Signed-off-by: Mateusz Jurczyk <[email protected]>
Signed-off-by: Marcel Holtmann <[email protected]>
Diffstat (limited to 'net/lapb/lapb_subr.c')
0 files changed, 0 insertions, 0 deletions