Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1313554 > unrolled thread

[PATCH 3.14 42/47] bluetooth: Validate socket address length in sco_sock_bind().

Started byGreg Kroah-Hartman <gregkh@linuxfoundation.org>
First post2016-01-20 23:10 +0100
Last post2016-01-20 23:10 +0100
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  [PATCH 3.14 42/47] bluetooth: Validate socket address length in sco_sock_bind(). Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-01-20 23:10 +0100

#1313554 — [PATCH 3.14 42/47] bluetooth: Validate socket address length in sco_sock_bind().

FromGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Date2016-01-20 23:10 +0100
Subject[PATCH 3.14 42/47] bluetooth: Validate socket address length in sco_sock_bind().
Message-ID<qT96Y-4g8-31@gated-at.bofh.it>
3.14-stable review patch.  If anyone has any objections, please let me know.

------------------

From: "David S. Miller" <davem@davemloft.net>

[ Upstream commit 5233252fce714053f0151680933571a2da9cbfb4 ]

Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
 net/bluetooth/sco.c |    3 +++
 1 file changed, 3 insertions(+)

--- a/net/bluetooth/sco.c
+++ b/net/bluetooth/sco.c
@@ -459,6 +459,9 @@ static int sco_sock_bind(struct socket *
 	if (!addr || addr->sa_family != AF_BLUETOOTH)
 		return -EINVAL;
 
+	if (addr_len < sizeof(struct sockaddr_sco))
+		return -EINVAL;
+
 	lock_sock(sk);
 
 	if (sk->sk_state != BT_OPEN) {

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web