> -----Original Message----- > From: ffmpeg-devel [mailto:ffmpeg-devel-boun...@ffmpeg.org] On Behalf Of Sasi > Inguva > Sent: Wednesday, January 18, 2017 3:30 AM > To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org> > Subject: Re: [FFmpeg-devel] mov: support for multiple edits and cenc > decryption > > Can you add a fate test ? Rest looks fine to me. > Attached: 1. Fate test 2. The original patch 3. Sample file - needs to be uploaded to $(TARGET_SAMPLES)/mov/mov-3elist-encrypted.mov
The sample file was created with this python script: import struct import os # encrypt os.system('ffmpeg -ignore_editlist 1 -i mov-3elist.mov -encryption_scheme cenc-aes-ctr -encryption_key 12345678901234567890123456789012 -encryption_kid 12345678901234567890123456789012 -vcodec copy -y mov-3elist-encrypted.mov') # reapply the complex edit list def growAtom(d, atom, size): atomPos = d.find(atom) size += struct.unpack('>L', d[(atomPos - 4):atomPos])[0] return d[:(atomPos - 4)] + struct.pack('>L', size) + d[atomPos:] d = file('mov-3elist-encrypted.mov', 'rb').read() d = d.replace( '00000024656474730000001C656C73740000000000000001000007D00000040000010000'.decode('hex'), '0000003C6564747300000034656C73740000000000000003000001F40000040000010000000001F400001C0000010000000003E80000340000010000'.decode('hex')) d = growAtom(d, 'trak', 0x18) d = growAtom(d, 'moov', 0x18) file('mov-3elist-encrypted.mov', 'wb').write(d) Thanks, Eran
0001-mov-add-fate-test-for-decryption-with-edit-list.patch
Description: 0001-mov-add-fate-test-for-decryption-with-edit-list.patch
0001-mov-fix-decryption-with-edit-list.patch
Description: 0001-mov-fix-decryption-with-edit-list.patch
mov-3elist-encrypted.mov
Description: mov-3elist-encrypted.mov
_______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel