Hi Antoine,
I've found a bug in FAPG version 0.41. If an .ogg file has a tag "ALBUM
ARTIST", the program will crash. The tag is detected and processed as a
normal "ARTIST" tag, however with an incorrect (huge) length. This causes a
buffer overflow in the strncpy to the artist buffer. I've created a patch
which adds a check on the "ALBUM ARTIST" tag (only for .ogg) before the check
on the "ARTIST" tag. I've tested it locally and it seems to do the job.
Kind Regards,
Patrick Smits
Signed-off-by: Antoine Jacquet <royale@zerezo.com>
title[size - 6] = '\0';
c += size;
}
+ if(strncasecmp(c, "ALBUM ARTIST=", 13) == 0) {
+ // ignore tag
+ size =
+ *(c - 4) + (*(c - 3) << 8) + (*(c - 2) << 16) +
+ (*(c - 1) << 24);
+ c += size;
+ }
if(strncasecmp(c, "ARTIST=", 7) == 0) {
size =
*(c - 4) + (*(c - 3) << 8) + (*(c - 2) << 16) +