https://github.com/z7pz/hls-encryption-prototype
Basic prototype implementation for HLS encryption process for protection videos. (AES-128 based)
https://github.com/z7pz/hls-encryption-prototype
hls hls-player protection
Last synced: 3 months ago
JSON representation
Basic prototype implementation for HLS encryption process for protection videos. (AES-128 based)
- Host: GitHub
- URL: https://github.com/z7pz/hls-encryption-prototype
- Owner: z7pz
- Created: 2024-01-02T11:09:33.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-01-02T18:45:42.000Z (over 2 years ago)
- Last Synced: 2025-04-10T09:48:25.729Z (about 1 year ago)
- Topics: hls, hls-player, protection
- Language: HTML
- Homepage:
- Size: 1.13 MB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# HLS encryption prototype (AES-128 based)
## Try to setup
### BACKEND
First of all you need to create an encryption key `enc.key` by using the following command:
```sh
openssl rand 16 > enc.key
```
then create `keyinfo` file
and it should be in this format:
```
link_of_enc.key
key_file_path
IV (optional)
```
for example
```
http://127.0.0.1:8080/enc.key
enc.key
```
and add your video in `./database`
run the following command to create the encrypted video
```sh
ffmpeg -y
-i './database/{{ your video name }}'
-hls_time 200
-hls_key_info_file enc.keyinfo
-hls_playlist_type vod
-hls_segment_filename "./d/chunk-%d.ts"
./d/test.m3u8
```
### FRONTEND
then you can go to the frontend file and run the html file
or you can run it through running `Live Server`
