projects
/
oweals
/
fstools.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5010710
)
fix vfat volume label
author
John Crispin
<john@phrozen.org>
Mon, 22 Jan 2018 06:22:40 +0000
(07:22 +0100)
committer
John Crispin
<john@phrozen.org>
Sun, 11 Feb 2018 13:29:22 +0000
(14:29 +0100)
the libblkid copies len+1 bytes causing a buffer overrun.
Signed-off-by: John Crispin <john@phrozen.org>
libblkid-tiny/vfat.c
patch
|
blob
|
history
diff --git
a/libblkid-tiny/vfat.c
b/libblkid-tiny/vfat.c
index e3daf75b2c2edd692d49f8b279c5805d006a3885..9f3d39551e016dffd14289c136c5469d8f715459 100644
(file)
--- a/
libblkid-tiny/vfat.c
+++ b/
libblkid-tiny/vfat.c
@@
-303,7
+303,7
@@
static int probe_vfat(blkid_probe pr, const struct blkid_idmag *mag)
struct vfat_super_block *vs;
struct msdos_super_block *ms;
const unsigned char *vol_label = 0;
- unsigned char *vol_serno = NULL, vol_label_buf[1
1]
;
+ unsigned char *vol_serno = NULL, vol_label_buf[1
2] = { 0 }
;
uint16_t sector_size = 0, reserved;
uint32_t cluster_count, fat_size;
const char *version = NULL;