Command line to add the encryption data to an existing mp4 file could be like the following:
MP4Box -isma -crypt kobudo-rei-uto_ismacrypt.xml kobudo-rei-uto_isma.mp4
The XML file referred as "kobudo-rei-uto_ismacrypt.xml" has the following content:
<?xml version="1.0" encoding="UTF-8" ?>
<ISMACryp>
<ISMACrypTrack
trackID="1"
key="0x180031a348c14d401143be02fe7708f5"
salt="0xd0763edaa9d9bd2a"
scheme_URI="urn:gpac:isma:encryption_scheme"
kms_URI="self"
selectiveType="5" />
</ISMACryp>
The resulting media file is attached.
Output of the command:
MP4Box -info 1 kobudo-rei-uto_isma.mp4
is the following:
Track # 1 Info - TrackID 1 - TimeScale 30000 - Duration 00:00:04.500
Media Info: Language "Undetermined" - Type "vide:encv" - 135 samples
Handler name: GPAC ISO Video Handler
MPEG-4 Config
Visual Stream - ObjectTypeIndication 0x21
AVC/H264 Video - Visual Size 784 x 320 - Profile High @ Level 4.1
NAL Unit length bits: 32
Pixel Aspect Ratio 1:1 - Indicated track size 784 x 320
Decoding Buffer size 10863 - Average bitrate 873 kbps - Max Bitrate 968 kbps
No stream dependencies for decoding
StreamPriority 0
*Encrypted stream - ISMA scheme iAEC (version 1)
scheme location: urn:gpac:isma:encryption_scheme
KMS location: key in file
Selective Encryption: Yes
Initialization Vector size: 32 bits
Computed info from media:
Total size 503484 bytes - Total samples duration 4500 ms
Average rate 983 kbps - Max Rate 969 kbps
'Infomation > Tip & Tech' 카테고리의 다른 글
안드로이드 동영상 스트리밍 (0) | 2012.10.18 |
---|---|
SATA vs FC(SAS) Disk IO 성능 비교 (0) | 2010.11.24 |
mp4 파일 시스템 기본 구(MP4 Structure) (0) | 2010.11.03 |
Windows 2008 FTP 세팅 (0) | 2010.11.01 |
iPhone encoding best pratices for live streaming (0) | 2010.10.25 |