paul o’brien - appliedtech.iit.edu · (video, audio, subtitle streams, etc) 2. decoding - use...

Post on 25-Jun-2020

3 Views

Category:

Documents

0 Downloads

Preview:

Click to see full reader

TRANSCRIPT

MP4 SteganographyPaul O’Brien

pobrien10@hawk.iit.edu

Raiven Johnsonrjohns42@hawk.iit.edu

1

The goal of this project was to develop a system andapplication that will allow a user to securely embed a payload using LSB (Least Significant Bit) Substitution on the Motion Vectors of a MP4 video file.

The system should be able to both embed and extract a covert payload

Project Goal

2

MP4 format:

3

Group of Pictures (GOP)In video coding, The Group of Pictures or GOP structure, specifies the arrangement order of intra-frames and the inter- frames. It is stored Media Data section of the MP4 container.• I-Frame: contain full picture

information.• P-Frame: forward predicted from

the last I-frame and P-frame.• B-Frame: forward and backward

predicted.

4

5

Macroblocks ● Each frame is made up of

blocks. These blocks, consisting of 8px x 8px, are created through the use of 4 smaller blocks (4px x 4px).

● Four of these blocks, 16px x 16px, make a macroblock. Macroblocks can be encoded various ways

Proposed SolutionUse of Macroblocks and Motion Vectors in I,P, and B frames.

6

Our approach (1)

We will use motion vectors to select frames that are acceptableto receive a payload and embed the information.

To select the candidate motion vectors we will use a thresholdmagnitude value approach.

The higher the magnitude, there is less distortion in the MV and thus, less chances of being noticed by an user.Magnitude depends on how far one block moves in the frame.Every MV whose magnitude is greater than the average magnitude of all MV will be eligible to cover the data.

7

Our approach (2)

Calculating the magnitude of the MVs

MV

Src (src_x, src_y).

. Dst (dst_x,

dst_y)

Magnitude(MV) =

8

Our approach (3)

For each eligible vector, we calculate the phase angle (Ө) todetermine

where are we going to embed the information reducing distortion.

If Ө is acute, we modify the horizontal component of MV

If Ө is obtuse, we modify the vertical component of MV

9

𝜭𝜭 = tan-1((dsty- srcy)/(dstx- srcx))

10

Our approach (4)Example of LSB substitution in an eligible MV:

Frame Num. Src_x Src_y Dst_x Dst_y Magnitude

1 240 198 255 210 10

2 145 178 130 170 11

Motion Vector 1𝜭𝜭=tan^-1(210-198)/(255-240)𝜭𝜭= 0.674740942 rad * 180/π𝜭𝜭= 38.7

Motion Vector 2𝜭𝜭=tan^-1(170-178)/(130-145)𝜭𝜭= 0.489957326 rad * 180/π𝜭𝜭= 28.1

𝜭𝜭 = tan-1((dsty- srcy)/(dstx- srcx))

Our approach (5)Example of LSB substitution in an eligible MV:

Frame Num. Src_x Src_y Dst_x Dst_y Magnitude

1 240 198 255 210 10

2 145 178 130 170 11

In binary:255 = 1111 1111130 = 1000 0010

New value for Dst_x:254 = 1111 1110131 = 1000 0011

Covert message in binary:01101000 01101001 00100001

Covert Message: “Hi!”

11

4 Processes Required for MP4 Manipulation

1. Demuxing - read a media file and split it into streams (video, audio, subtitle streams, etc)

2. Decoding - Use decoder to uncompress streams, read data frame by frame

3. Encoding - Compress each frame, convert raw frame data into language readable/playable by specified format

4. Muxing - Join the encoded streams back together and write them the desired file

12

Demuxing and Decoding

13

Encoding and Muxing

14

GUI

15

Accomplished

● Read and analyze an MP4 file● Convert payload into binary● Motion vector insertion algorithm developed

and coded● GUI is created functioning for insertion● Extraction algorithm developed● Encoding the new video stream/maintaining

modified motion vectors

16

In Progress● Create working interface file for SWIG

○ Integrating backend code for program functionality (C++) into functioning GUI buttons (Python)

● Properly encoding video stream without losing data

17

Analysis

● MP4 Videos have a high storage capacity when it comes to embedding payloads on the motion vectors

● Motion vectors are easily accessible and easily modifiable

● Using ffmpeg copying the context of the original video is not a complete copy

18

Analysis

● It is necessary to write new packets of data to a new stream frame by frame rather than cohesively at the end of the process

● Original extraction algorithm may be flawed, may need to come up with another way to perform the extraction

19

Expectations Moving Forward

20

● Combine the GUI with the backend● Produce a fully working MP4 file with the

embedded data● Revise extraction algorithm● Perform extraction

Thank you!

21

top related