Skip to content

truedread/pymp4decrypt

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pymp4decrypt

A Python MP4 decrypter for CENC encrypted MP4s

pymp4decrypt uses the excellent parsing library by beardypig, but with some extra modifications for CENC boxes.

Usage

By itself as a script:

python decrypt.py -k KEY -i INPUT_FILE_ENCRYPTED.mp4 -o OUTPUT_FILE_DECRYPTED.mp4

As a library:

>>> import binascii
>>> import pymp4decrypt
>>> enc = open('encrypted.mp4', 'rb')
>>> dec = open('decrypted.mp4', 'wb')
>>> key = binascii.unhexlify('4ce68c303ae037a59888d4866de39ffb')
>>> pymp4decrypt.decrypt(key, enc, dec)
>>> 

About

A Python MP4 decrypter for CENC encrypted MP4s

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages