projects
/
GitHub
/
MotorolaMobilityLLC
/
kernel-slsi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ed30013
)
Staging: otus: off by one in usbdrvwext_siwessid()
author
Dan Carpenter
<error27@gmail.com>
Mon, 28 Dec 2009 17:01:34 +0000
(19:01 +0200)
committer
Greg Kroah-Hartman
<gregkh@suse.de>
Thu, 4 Mar 2010 00:42:39 +0000
(16:42 -0800)
A 33 char ESSID is too long and it could cause a buffer overflow
a couple lines below when we put a NULL terminator on the end.
Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/otus/ioctl.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/staging/otus/ioctl.c
b/drivers/staging/otus/ioctl.c
index 6808e69fb354970376bf93a9b837dac8a85cbb0b..86d93330acad4db399ced8b1874208d8654bcf35 100644
(file)
--- a/
drivers/staging/otus/ioctl.c
+++ b/
drivers/staging/otus/ioctl.c
@@
-930,7
+930,7
@@
int usbdrvwext_siwessid(struct net_device *dev,
return -EINVAL;
if (essid->flags == 1) {
- if (essid->length >
(IW_ESSID_MAX_SIZE + 1)
)
+ if (essid->length >
IW_ESSID_MAX_SIZE
)
return -E2BIG;
if (copy_from_user(&EssidBuf, essid->pointer, essid->length))