This repository implements encryption of video using the AES algorithm, enabling secure and robust transmission of video. The raw image stream from the camera is first encoded using H.264 compression and the generated packets is encrypted using AES. This keeps the data secure when it is transmitted over a network. The ecypted packets is then decrypted and decoded to to get back the images captured by the camera.
To run the examples in the repository, you are required to install the following:
FFmpeg: Download the required libs using the following link - https://ffmpeg.org/download.html
This is implemented in encoder.cpp
- Compile the application:
make -f Makefile.enc clean && make -f Makefile.enc
- Run the application:
./encoder <path to yuv file> <number of frames to encode>
The YUV file should be a YUV420 video of 1920*1280 resolution.
Sample:
./encoder ./sample.yuv 120
The encoded packets are stored in outputs/plain directory. The packets are then encrypted and stored in outputs/enc directory
This is implemented in decoder.cpp
- Compile the application:
make -f Makefile.dec clean && make -f Makefile.dec
- Run the application:
./decoder <path to folder> <num of frames>'
The "path to folder" indicates the folder containing the encoded + encrypted packets. This would have generated by encoder.cpp described above.
Sample:
./decoder ./outputs/enc/ 120
The decrypted and decoded frames will be stored in outputs/decrypt_images