You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To trigger these segmentation faults, compile bento4 with ASAN:
./mp4info --verbose --show-layout --show-samples --show-sample-data PoC
ASAN output and stack trace of two segmentation faults:
==9295==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000008 (pc 0x5654dd81ac13 bp 0x7ffde5211e30 sp 0x7ffde5211e20 T0)
==9295==The signal is caused by a READ memory access.
==9295==Hint: address points to the zero page.
#0 0x5654dd81ac12 in AP4_Descriptor::GetTag() (/home/bowen/Bowen/gitrepo/bento4/bento4-asan/Build/mp4info+0x39ac12) #1 0x5654dd81acff in AP4_DescriptorFinder::Test(AP4_Descriptor*) const (/home/bowen/Bowen/gitrepo/bento4/bento4-asan/Build/mp4info+0x39acff) #2 0x5654dd81b640 in AP4_List<AP4_Descriptor>::Find(AP4_List<AP4_Descriptor>::Item::Finder const&, AP4_Descriptor*&) const /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4List.h:431 #3 0x5654dd8c2a2f in AP4_DecoderConfigDescriptor::GetDecoderSpecificInfoDescriptor() const /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4DecoderConfigDescriptor.cpp:159 #4 0x5654dd843fff in AP4_MpegSampleDescription::AP4_MpegSampleDescription(unsigned int, AP4_EsdsAtom*) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4SampleDescription.cpp:591 #5 0x5654dd84481b in AP4_MpegAudioSampleDescription::AP4_MpegAudioSampleDescription(unsigned int, unsigned short, unsigned short, AP4_EsdsAtom*) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4SampleDescription.cpp:697 #6 0x5654dd84a5ea in AP4_MpegAudioSampleEntry::ToSampleDescription() /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4SampleEntry.cpp:678 #7 0x5654dd85dee9 in AP4_StsdAtom::GetSampleDescription(unsigned int) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4StsdAtom.cpp:181 #8 0x5654dd8a29c2 in AP4_AtomSampleTable::GetSampleDescription(unsigned int) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AtomSampleTable.cpp:207 #9 0x5654dd872528 in AP4_Track::GetSampleDescription(unsigned int) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4Track.cpp:445 #10 0x5654dd7ab775 in ShowTrackInfo_Text /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Apps/Mp4Info/Mp4Info.cpp:1152 #11 0x5654dd7ac384 in ShowTrackInfo /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Apps/Mp4Info/Mp4Info.cpp:1276 #12 0x5654dd7ac9be in ShowTracks /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Apps/Mp4Info/Mp4Info.cpp:1386 #13 0x5654dd7ae655 in main /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Apps/Mp4Info/Mp4Info.cpp:1650 #14 0x7fb77c5bdb96 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x21b96) #15 0x5654dd7a3d59 in _start (/home/bowen/Bowen/gitrepo/bento4/bento4-asan/Build/mp4info+0x323d59)
Two segmentation faults are detected in mp4info.
git commit: 7242177
To trigger these segmentation faults, compile bento4 with ASAN:
./mp4info --verbose --show-layout --show-samples --show-sample-data PoC
ASAN output and stack trace of two segmentation faults:
==9295==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000008 (pc 0x5654dd81ac13 bp 0x7ffde5211e30 sp 0x7ffde5211e20 T0)
==9295==The signal is caused by a READ memory access.
==9295==Hint: address points to the zero page.
#0 0x5654dd81ac12 in AP4_Descriptor::GetTag() (/home/bowen/Bowen/gitrepo/bento4/bento4-asan/Build/mp4info+0x39ac12)
#1 0x5654dd81acff in AP4_DescriptorFinder::Test(AP4_Descriptor*) const (/home/bowen/Bowen/gitrepo/bento4/bento4-asan/Build/mp4info+0x39acff)
#2 0x5654dd81b640 in AP4_List<AP4_Descriptor>::Find(AP4_List<AP4_Descriptor>::Item::Finder const&, AP4_Descriptor*&) const /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4List.h:431
#3 0x5654dd8c2a2f in AP4_DecoderConfigDescriptor::GetDecoderSpecificInfoDescriptor() const /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4DecoderConfigDescriptor.cpp:159
#4 0x5654dd843fff in AP4_MpegSampleDescription::AP4_MpegSampleDescription(unsigned int, AP4_EsdsAtom*) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4SampleDescription.cpp:591
#5 0x5654dd84481b in AP4_MpegAudioSampleDescription::AP4_MpegAudioSampleDescription(unsigned int, unsigned short, unsigned short, AP4_EsdsAtom*) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4SampleDescription.cpp:697
#6 0x5654dd84a5ea in AP4_MpegAudioSampleEntry::ToSampleDescription() /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4SampleEntry.cpp:678
#7 0x5654dd85dee9 in AP4_StsdAtom::GetSampleDescription(unsigned int) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4StsdAtom.cpp:181
#8 0x5654dd8a29c2 in AP4_AtomSampleTable::GetSampleDescription(unsigned int) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AtomSampleTable.cpp:207
#9 0x5654dd872528 in AP4_Track::GetSampleDescription(unsigned int) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4Track.cpp:445
#10 0x5654dd7ab775 in ShowTrackInfo_Text /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Apps/Mp4Info/Mp4Info.cpp:1152
#11 0x5654dd7ac384 in ShowTrackInfo /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Apps/Mp4Info/Mp4Info.cpp:1276
#12 0x5654dd7ac9be in ShowTracks /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Apps/Mp4Info/Mp4Info.cpp:1386
#13 0x5654dd7ae655 in main /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Apps/Mp4Info/Mp4Info.cpp:1650
#14 0x7fb77c5bdb96 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x21b96)
#15 0x5654dd7a3d59 in _start (/home/bowen/Bowen/gitrepo/bento4/bento4-asan/Build/mp4info+0x323d59)
mp4info-1.pdf
=================================================================
==13584==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000000 (pc 0x7fd57cc50634 bp 0x7ffcc3164310 sp 0x7ffcc3163a80 T0)
==13584==The signal is caused by a READ memory access.
==13584==Hint: address points to the zero page.
#0 0x7fd57cc50633 (/usr/lib/x86_64-linux-gnu/libasan.so.4+0x79633)
#1 0x55acb1b022f8 in AP4_DataBuffer::SetData(unsigned char const*, unsigned int) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4DataBuffer.cpp:175
#2 0x55acb1aef76c in AP4_AvccAtom::AP4_AvccAtom(unsigned int, unsigned char const*) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AvccAtom.cpp:173
#3 0x55acb1aee8a5 in AP4_AvccAtom::Create(unsigned int, AP4_ByteStream&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AvccAtom.cpp:95
#4 0x55acb1aeadb4 in AP4_AtomFactory::CreateAtomFromStream(AP4_ByteStream&, unsigned int, unsigned int, unsigned long long, AP4_Atom*&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AtomFactory.cpp:491
#5 0x55acb1ae8fe2 in AP4_AtomFactory::CreateAtomFromStream(AP4_ByteStream&, unsigned long long&, AP4_Atom*&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AtomFactory.cpp:231
#6 0x55acb1afa706 in AP4_ContainerAtom::ReadChildren(AP4_AtomFactory&, AP4_ByteStream&, unsigned long long) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4ContainerAtom.cpp:194
#7 0x55acb1b61982 in AP4_SampleEntry::Read(AP4_ByteStream&, AP4_AtomFactory&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4SampleEntry.cpp:115
#8 0x55acb1b65bfe in AP4_VisualSampleEntry::AP4_VisualSampleEntry(unsigned int, unsigned int, AP4_ByteStream&, AP4_AtomFactory&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4SampleEntry.cpp:742
#9 0x55acb1b673ee in AP4_AvcSampleEntry::AP4_AvcSampleEntry(unsigned int, unsigned int, AP4_ByteStream&, AP4_AtomFactory&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4SampleEntry.cpp:994
#10 0x55acb1ae9b1d in AP4_AtomFactory::CreateAtomFromStream(AP4_ByteStream&, unsigned int, unsigned int, unsigned long long, AP4_Atom*&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AtomFactory.cpp:316
#11 0x55acb1ae8fe2 in AP4_AtomFactory::CreateAtomFromStream(AP4_ByteStream&, unsigned long long&, AP4_Atom*&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AtomFactory.cpp:231
#12 0x55acb1b78261 in AP4_StsdAtom::AP4_StsdAtom(unsigned int, unsigned char, unsigned int, AP4_ByteStream&, AP4_AtomFactory&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4StsdAtom.cpp:101
#13 0x55acb1b77acf in AP4_StsdAtom::Create(unsigned int, AP4_ByteStream&, AP4_AtomFactory&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4StsdAtom.cpp:57
#14 0x55acb1aea994 in AP4_AtomFactory::CreateAtomFromStream(AP4_ByteStream&, unsigned int, unsigned int, unsigned long long, AP4_Atom*&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AtomFactory.cpp:436
#15 0x55acb1ae8fe2 in AP4_AtomFactory::CreateAtomFromStream(AP4_ByteStream&, unsigned long long&, AP4_Atom*&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AtomFactory.cpp:231
#16 0x55acb1afa706 in AP4_ContainerAtom::ReadChildren(AP4_AtomFactory&, AP4_ByteStream&, unsigned long long) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4ContainerAtom.cpp:194
#17 0x55acb1afa17a in AP4_ContainerAtom::AP4_ContainerAtom(unsigned int, unsigned long long, bool, AP4_ByteStream&, AP4_AtomFactory&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4ContainerAtom.cpp:139
#18 0x55acb1af9cd8 in AP4_ContainerAtom::Create(unsigned int, unsigned long long, bool, bool, AP4_ByteStream&, AP4_AtomFactory&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4ContainerAtom.cpp:88
#19 0x55acb1aec209 in AP4_AtomFactory::CreateAtomFromStream(AP4_ByteStream&, unsigned int, unsigned int, unsigned long long, AP4_Atom*&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AtomFactory.cpp:776
#20 0x55acb1ae8fe2 in AP4_AtomFactory::CreateAtomFromStream(AP4_ByteStream&, unsigned long long&, AP4_Atom*&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AtomFactory.cpp:231
#21 0x55acb1afa706 in AP4_ContainerAtom::ReadChildren(AP4_AtomFactory&, AP4_ByteStream&, unsigned long long) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4ContainerAtom.cpp:194
#22 0x55acb1afa17a in AP4_ContainerAtom::AP4_ContainerAtom(unsigned int, unsigned long long, bool, AP4_ByteStream&, AP4_AtomFactory&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4ContainerAtom.cpp:139
#23 0x55acb1af9cd8 in AP4_ContainerAtom::Create(unsigned int, unsigned long long, bool, bool, AP4_ByteStream&, AP4_AtomFactory&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4ContainerAtom.cpp:88
#24 0x55acb1aec209 in AP4_AtomFactory::CreateAtomFromStream(AP4_ByteStream&, unsigned int, unsigned int, unsigned long long, AP4_Atom*&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AtomFactory.cpp:776
#25 0x55acb1ae8fe2 in AP4_AtomFactory::CreateAtomFromStream(AP4_ByteStream&, unsigned long long&, AP4_Atom*&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AtomFactory.cpp:231
#26 0x55acb1afa706 in AP4_ContainerAtom::ReadChildren(AP4_AtomFactory&, AP4_ByteStream&, unsigned long long) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4ContainerAtom.cpp:194
#27 0x55acb1afa17a in AP4_ContainerAtom::AP4_ContainerAtom(unsigned int, unsigned long long, bool, AP4_ByteStream&, AP4_AtomFactory&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4ContainerAtom.cpp:139
#28 0x55acb1af9cd8 in AP4_ContainerAtom::Create(unsigned int, unsigned long long, bool, bool, AP4_ByteStream&, AP4_AtomFactory&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4ContainerAtom.cpp:88
#29 0x55acb1aec209 in AP4_AtomFactory::CreateAtomFromStream(AP4_ByteStream&, unsigned int, unsigned int, unsigned long long, AP4_Atom*&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AtomFactory.cpp:776
#30 0x55acb1ae8fe2 in AP4_AtomFactory::CreateAtomFromStream(AP4_ByteStream&, unsigned long long&, AP4_Atom*&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AtomFactory.cpp:231
#31 0x55acb1afa706 in AP4_ContainerAtom::ReadChildren(AP4_AtomFactory&, AP4_ByteStream&, unsigned long long) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4ContainerAtom.cpp:194
#32 0x55acb1afa17a in AP4_ContainerAtom::AP4_ContainerAtom(unsigned int, unsigned long long, bool, AP4_ByteStream&, AP4_AtomFactory&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4ContainerAtom.cpp:139
#33 0x55acb1b8eaae in AP4_TrakAtom::AP4_TrakAtom(unsigned int, AP4_ByteStream&, AP4_AtomFactory&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4TrakAtom.cpp:165
#34 0x55acb1aed279 in AP4_TrakAtom::Create(unsigned int, AP4_ByteStream&, AP4_AtomFactory&) (/home/bowen/Bowen/gitrepo/bento4/bento4-asan/Build/mp4info+0x352279)
#35 0x55acb1aea62d in AP4_AtomFactory::CreateAtomFromStream(AP4_ByteStream&, unsigned int, unsigned int, unsigned long long, AP4_Atom*&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AtomFactory.cpp:391
#36 0x55acb1ae8fe2 in AP4_AtomFactory::CreateAtomFromStream(AP4_ByteStream&, unsigned long long&, AP4_Atom*&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AtomFactory.cpp:231
#37 0x55acb1afa706 in AP4_ContainerAtom::ReadChildren(AP4_AtomFactory&, AP4_ByteStream&, unsigned long long) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4ContainerAtom.cpp:194
#38 0x55acb1afa17a in AP4_ContainerAtom::AP4_ContainerAtom(unsigned int, unsigned long long, bool, AP4_ByteStream&, AP4_AtomFactory&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4ContainerAtom.cpp:139
#39 0x55acb1b2c7b2 in AP4_MoovAtom::AP4_MoovAtom(unsigned int, AP4_ByteStream&, AP4_AtomFactory&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4MoovAtom.cpp:80
#40 0x55acb1aed213 in AP4_MoovAtom::Create(unsigned int, AP4_ByteStream&, AP4_AtomFactory&) (/home/bowen/Bowen/gitrepo/bento4/bento4-asan/Build/mp4info+0x352213)
#41 0x55acb1aea4a6 in AP4_AtomFactory::CreateAtomFromStream(AP4_ByteStream&, unsigned int, unsigned int, unsigned long long, AP4_Atom*&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AtomFactory.cpp:371
#42 0x55acb1ae8fe2 in AP4_AtomFactory::CreateAtomFromStream(AP4_ByteStream&, unsigned long long&, AP4_Atom*&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AtomFactory.cpp:231
#43 0x55acb1ae844f in AP4_AtomFactory::CreateAtomFromStream(AP4_ByteStream&, AP4_Atom*&) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4AtomFactory.cpp:151
#44 0x55acb1b099cf in AP4_File::ParseStream(AP4_ByteStream&, AP4_AtomFactory&, bool) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4File.cpp:104
#45 0x55acb1b0963e in AP4_File::AP4_File(AP4_ByteStream&, bool) /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Core/Ap4File.cpp:78
#46 0x55acb1ac94c2 in main /home/bowen/Bowen/gitrepo/bento4/bento4-asan/Source/C++/Apps/Mp4Info/Mp4Info.cpp:1634
#47 0x7fd57c266b96 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x21b96)
#48 0x55acb1abed59 in _start (/home/bowen/Bowen/gitrepo/bento4/bento4-asan/Build/mp4info+0x323d59)
mp4info-4.pdf
The text was updated successfully, but these errors were encountered: