Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When open a crafted mp4 file, The program could enter AP4_File::ParseStream , and it could hang on, then program could be not response
mp4
AP4_File::ParseStream
void AP4_File::ParseStream(AP4_ByteStream& stream, AP4_AtomFactory& atom_factory, bool moov_only) { // parse top-level atoms AP4_Atom* atom; AP4_Position stream_position; bool keep_parsing = true; while (keep_parsing && AP4_SUCCEEDED(stream.Tell(stream_position)) && AP4_SUCCEEDED(atom_factory.CreateAtomFromStream(stream, atom))) { AddChild(atom); switch (atom->GetType()) { case AP4_ATOM_TYPE_MOOV: m_Movie = new AP4_Movie(AP4_DYNAMIC_CAST(AP4_MoovAtom, atom), stream, false); if (moov_only) keep_parsing = false; break; case AP4_ATOM_TYPE_FTYP: m_FileType = AP4_DYNAMIC_CAST(AP4_FtypAtom, atom); break; case AP4_ATOM_TYPE_MDAT: // see if we are before the moov atom if (m_Movie == NULL) m_MoovIsBeforeMdat = false; break; } } }
The poc
https://gitee.com/hac425/fuzz_data/blob/master/poc.mp4
The text was updated successfully, but these errors were encountered:
6acb92d
barbibulle
No branches or pull requests
When open a crafted
mp4file, The program could enterAP4_File::ParseStream, and it could hang on, then program could be not responseThe poc
The text was updated successfully, but these errors were encountered: