Netflix MSL Reader
Intercept MSL requests and responses from Netflix
- 👁️ Transparent MSL requests and responses interception
- 🔓 Decrypt content and return parsed data
- 📜 Save logs data for let you analyse data later
- git
- mitmproxy
- Python (up to 3.12)
- Poetry
- Any proxy browser extension (like FoxyProxy)
- Valid premium Netflix account
Important
To intercept SSL requests and responses with mitmproxy, you need to install mitmproxy certificate.
$ git clone https://github.com/retouching/nf-msl-reader.git
$ cd nf-msl-reader
$ poetry install
Important
If you are logged already, you have to delete the netflix MSL session to force it to recreate the session. To do it:
- Go on Netflix
- Open devtools (F12)
- Go in Application > IndexedDB > netflix.player and click "Delete database"
- Start mitmproxy with script enabled:
$ mitmdump -s run.py -q
-
Switch to mitmproxy proxy on proxy browser extension
-
Press
CTRL + F5
on Netflix and start navigating. Clear cache is important beacause the script update cadmium playercore file. -
You can get intercepted requests and responses in logs folder.
If all is done, you have this on your terminal:
[!] Exchange keys not found! Waiting for keys exchange ...
[+] Initialized logs
[+] Update cadmium playercore file with our rsa proxy key
[+] Receive Netflix MSL request
[+] Receive key exchange request for Netflix
[+] Change public key used for exchange to read server keys later
[+] Send updated public key exchange to Netflix
[+] Receive Netflix MSL response
[+] Receive key exchange response from Netflix
[+] Save MSL keys
[+] Saved MSL request "xxx"
[+] Saving keys
[+] Receive Netflix MSL request
[+] Receive Netflix MSL response
[+] Saved MSL request "xxx"
Log file:
{
"url": string,
"requested_at": number,
"raw": {
"request": any[],
"response": any[]
},
"parsed": {
"request": {
"header": any,
"data": any
},
"response": {
"header": any,
"data": any
}
}
}
README style taken from devine