Update README.md

Proxy stuff
Update README.md - Grammar
Update issue templates
Update amazon.py
Star history dark theme
This commit is contained in:
chu23465 2025-03-23 10:03:00 +05:30
parent 05ed9d57df
commit ddcb82a853
4 changed files with 154 additions and 25 deletions

21
.github/ISSUE_TEMPLATE/bug_report.md vendored Normal file
View File

@ -0,0 +1,21 @@
---
name: Bug report
about: Create a report to help us improve
title: ''
labels: ''
assignees: chu23465
---
**Describe the bug**
A clear and concise description of what the bug is.
Command used - `[your command]`
**Log**
Add the appropriate log(s) from `vinetrimmer/Logs/` directory. Either add them as text to the issue like below:
```
......Log......
```
Or upload them as attachments to the issue.

View File

@ -0,0 +1,20 @@
---
name: Feature request
about: Suggest an idea for this project
title: ''
labels: ''
assignees: ''
---
**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
**Describe the solution you'd like**
A clear and concise description of what you want to happen.
**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.
**Additional context**
Add any other context or screenshots about the feature request here.

136
README.md
View File

@ -1,7 +1,13 @@
# VineTrimmer-PlayReady # VineTrimmer-PlayReady
A tool to download and remove DRM from streaming services. A version of an old fork of [devine](https://github.com/devine-dl/devine). A tool to download and remove DRM from streaming services.
Modified to remove Playready DRM instead of Widevine. Modified to remove Playready DRM instead of Widevine.
## Disclaimer!!!
This project is ONLY for educational/archival/personal purposes. I do not condone piracy in any form.
I AM NOT taking credit for the entirety of this project. This project is based on a version of an old fork of [devine](https://github.com/devine-dl/devine) that was found floating around online. I AM taking credit for about 20% of the additional stuff that I personally worked on.
## Features ## Features
- Progress Bars for decryption ([mp4decrypt](https://github.com/chu23465/bentoOldFork), Shaka) - Progress Bars for decryption ([mp4decrypt](https://github.com/chu23465/bentoOldFork), Shaka)
- Refresh Token fixed for Amazon service - Refresh Token fixed for Amazon service
@ -9,30 +15,63 @@ Modified to remove Playready DRM instead of Widevine.
- ISM manifest support (Microsoft Smooth Streaming) (WIP/Experimental) - ISM manifest support (Microsoft Smooth Streaming) (WIP/Experimental)
- N_m3u8DL-RE downloader support - N_m3u8DL-RE downloader support
## Broken ## Broken / To-Do (Descending order of priority)
- `--bitrate CVBR+CBR` is currently broken
- Atmos audio with ISM manifest (Amazon) is currently broken (Needs a working init.mp4). If the title has the atmos audio in MPD then it should work. ### Amazon Specific
- ATVP service is currently broken in dev branch
- Netflix service is currently broken (will probably be fixed Soon™) - [ ] `--bitrate CVBR+CBR` is currently broken (results in max() function error)
- [ ] Optimize Amazon licencing function.
- [ ] Get highest quality CBR+CVBR MPD+ISM by default to AMZN
- [ ] Add listing ism tracks and mpd tracks simultaneously
- [ ] For videos, download init.mp4 using N_m3u8, mediainfo it to get FPS, HDR info
- [ ] Manifest url caching system for every key/Track object.
- [ ] Atmos audio with ISM manifest (Amazon) is currently broken (Needs a working initialization segment - init.mp4. If the title has the atmos audio in MPD then it should work.)
- [ ] ISM EAC3 -> for ddp / atmos needs dec3 box ?
### Other services
- [ ] Fix cdm.type errors.
- [ ] MAX - Fix HDR10/DV --list
- [ ] ATVP service is currently broken in dev branch
- [ ] Netflix service is currently broken (will probably be fixed Soon™)
- [ ] Fix original language (Was removed as workaround for a bug)
- [ ] Move to requests, curl or otherwise to download subtitles (?)
- [ ] Integrate [subby](https://github.com/vevv/subby)
- [ ] Licensing before download (?)
- [ ] Add MoviesAnywhere, ParmountPlus, DisneyPlus services.
- [ ] Implement a scan/hammer/cache keys for each service
If anyone has any idea how to fix above issues, feel free to open a pull request. If anyone has any idea how to fix above issues, feel free to open a pull request.
## Donating
I am an independent developer right now. I work on this project in my free time. If you could support me that would be immensely helpful. All supporters will get a special mention in the README. Thank you in advance.
My [Buymeacoffee](https://buymeacoffee.com/chu23465).
## Usage ## Usage
1. Make sure git is installed in your system by running `git --version`. If not refer to [link](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git) 1. Install Microsoft Visual C++ Redistributable - [link](https://aka.ms/vs/17/release/vc_redist.x64.exe)
2. Choose a branch, either `dev` or `main`. Use below command to download. (Recommended instead of downloading zip) 2. Ensure Python is installed in your system (has to be not be from the the Microsoft Store). Refer to [link](https://www.python.org/downloads/) or on Ubuntu -> `sudo apt install python3`.
3. Make sure git is installed in your system by running `git --version`. If not refer to [link](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git)
4. Choose a branch, either `dev` or `main`. Use below command to download. (Recommended instead of downloading zip)
```bash ```bash
git clone -b <branch-name> --single-branch https://github.com/chu23465/VT-PR git clone -b <branch-name> --single-branch https://github.com/chu23465/VT-PR
``` ```
3. Navigate and find `install.bat` 5. Navigate and find `install.bat`
4. Run `install.bat` 6. Run `install.bat`
5. Activate venv using `venv.cmd`. 7. Activate venv using `venv.cmd`.
6. Run desired command using poetry. 8. Run desired command using poetry.
## Updating ## Updating
@ -53,7 +92,7 @@ If anyone has any idea how to fix above issues, feel free to open a pull request
`decryptor:` either `mp4decrypt` or `packager` `decryptor:` either `mp4decrypt` or `packager`
(shaka-packager fails to decrypt files downloaded from MSS manifests) (shaka-packager fails to decrypt files downloaded from ISM/Microsoft Smooth Streaming manifests)
`tag:` tag for your release group `tag:` tag for your release group
@ -115,6 +154,7 @@ COMMAND :-
| ATVP | AppleTVPlus | https://tv.apple.com | | ATVP | AppleTVPlus | https://tv.apple.com |
| MAX | Max | https://max.com | | MAX | Max | https://max.com |
| NF | Netflix | https://netflix.com | | NF | Netflix | https://netflix.com |
| PCOK | Peacock | https://peacocktv.com/ |
### Amazon Specific Options ### Amazon Specific Options
@ -162,9 +202,9 @@ https://www.primevideo.com/region/eu/ontv/code?ref_=atv_auth_red_aft
Login and get to the code pair page. Extract cookies from that page using [Open Cookies.txt](https://chromewebstore.google.com/detail/open-cookiestxt/gdocmgbfkjnnpapoeobnolbbkoibbcif). Login and get to the code pair page. Extract cookies from that page using [Open Cookies.txt](https://chromewebstore.google.com/detail/open-cookiestxt/gdocmgbfkjnnpapoeobnolbbkoibbcif).
Save it to the path `vinetrimmer/Cookies/Amazon/default.txt`. Save it to the path `vinetrimmer/Cookies/Amazon/default.txt`. Pay attention to path if you are on Linux. Path is case sensitive and needs the capital `C` for `Cookies` and capital `A` for `Amazon`.
When caching cookies, use a profile without PIN. Otherwise it causes errors. When caching cookies, use a profile without PIN. Otherwise it may cause errors.
### Peacock ### Peacock
@ -175,11 +215,12 @@ When caching cookies, use a profile without PIN. Otherwise it causes errors.
Amazon Example: Amazon Example:
```bash ```bash
poetry run vt dl -al en -sl en --selected -q 2160 -r HDR -w S01E18-S01E25 AMZN -b CBR --ism 0IQZZIJ6W6TT2CXPT6ZOZYX396 poetry run vt dl -al en -sl all --selected -q 2160 -r HDR -w S01E18-S01E25 AMZN -b CBR --ism 0IQZZIJ6W6TT2CXPT6ZOZYX396
``` ```
Above command: Above command:
- gets english subtitles + audio, - gets english audio,
- gets all available subtitles,
- selects the HDR + 4K track, - selects the HDR + 4K track,
- gets episodes from S01E18 to S01E25 from Amazon - gets episodes from S01E18 to S01E25 from Amazon
- with CBR bitrate, - with CBR bitrate,
@ -189,16 +230,31 @@ Above command:
AppleTV Example: AppleTV Example:
```bash ```bash
poetry run vt dl -al en -sl en --list -q 720 --proxy http://192.168.0.99:9766 -w S01E01 ATVP umc.cmc.1nfdfd5zlk05fo1bwwetzldy3 poetry run vt dl -al en,it -sl en,es -q 720 --proxy http://192.168.0.99:9766 -w S01E01 ATVP umc.cmc.1nfdfd5zlk05fo1bwwetzldy3
``` ```
Above command: Above command:
- gets english subtitles + audio, - gets english, italian audio
- gets english, spanish subtitles,
- lists all possible qualities, - lists all possible qualities,
- selects 720p video track, - selects 720p video track,
- uses the proxy for licensing, - uses the proxy for licensing,
- gets the first episode of first season (i.e S01E01) - gets the first episode of first season (i.e S01E01)
- of the title umc.cmc.1nfdfd5zlk05fo1bwwetzldy3 - of the title-ID umc.cmc.1nfdfd5zlk05fo1bwwetzldy3
Max Example:
```bash
poetry run vt dl -al en -sl en --keys --proxy http://192.168.0.99:9766 MAX https://play.max.com/show/5756c2bf-36f8-4890-b1f9-ef168f1d8e9c
```
Above command:
- gets english subtitles + audio,
- skips download and only gets the content keys,
- from MAX
- uses specified proxy
- defaulting to HD for video
- title-ID is 5756c2bf-36f8-4890-b1f9-ef168f1d8e9c
## Proxy ## Proxy
@ -230,15 +286,47 @@ Tested so far on Amazon, AppleTVPlus, Max.
...(other flags)... --proxy http://192.168.0.141:9766 ....... ...(other flags)... --proxy http://192.168.0.141:9766 .......
``` ```
If you are using other VPNs, extract the proxy (use the browser extension to do this). It will look something like `http(s)://username:pass@host/IP`. Ex -> `https://user:pass@in-mum.prod.surfshark.com:443`. Pass it like below:
```bash
...(other flags)... --proxy https://user:pass@in-mum.prod.surfshark.com:443 .......
```
## Other ## Other
- For `--keys` to work with ATVP you need to pass the `--no-subs` flag also - For `--keys` to work with ATVP you need to pass the `--no-subs` flag.
- Nuikta compile is an option to run on various linux distributions. - Errors arise when running VT within Docker or Conda like python environments. Make sure to use proper python3.
- Errors arise when running VT within Docker or Conda like python distributions. Make sure to use proper python3.
- To use programs in `scripts` folder, first activate venv then, then - - To use programs in `scripts` folder, first activate venv then, then -
```bash ```bash
poetry run python scripts/ParseKeybox.py poetry run python scripts/ParseKeybox.py
``` ```
- There is another way of running this instead of using `poetry`. In root folder of VT-PR there is a `vt.py` (which is essentially the same as `vinetrimmer/vinetrimmer.py`). Activate venv, then:
```bash
python vt.py dl ......(rest of the command as before).......
```
This is useful for debugging/stepping through in IDE's without having to deal with poetry.
- Nuitka compile:
- Activate venv, then
- `python -m pip install nuitka`
- Verify using command `nuitka --version`
- Then:
```bash
nuitka --standalone --output-dir=dist --windows-console-mode=force vt.py --include-data-dir=./vinetrimmer/=vinetrimmer/ --include-data-dir=./binaries/=binaries
```
- `--standalone` will give a folder of compiled pythonic objects. Zip it to distribute. This is recommended.
- If you don't want to carry around/deal with a zip, instead use `--onefile`. This has the drawback of setting the default folders to the temp folder in whatever OS you are using. This could be fixed with some extra code but that is currently not implemented.
## Star History ## Star History
[![Star History Chart](https://api.star-history.com/svg?repos=chu23465/VT-PR&type=Date)](https://www.star-history.com/#chu23465/VT-PR&Date) <a href="https://www.star-history.com/#chu23465/VT-PR&Date">
<picture>
<source media="(prefers-color-scheme: dark)" srcset="https://api.star-history.com/svg?repos=chu23465/VT-PR&type=Date&theme=dark" />
<source media="(prefers-color-scheme: light)" srcset="https://api.star-history.com/svg?repos=chu23465/VT-PR&type=Date" />
<img alt="Star History Chart" src="https://api.star-history.com/svg?repos=chu23465/VT-PR&type=Date" />
</picture>
</a>

View File

@ -120,7 +120,7 @@ class Amazon(BaseService):
if "linux" in platform: if "linux" in platform:
import yaml import yaml
#Read YAML file #Read YAML file
with open("/content/vinetrimmer/config/Services/amazon.yml", 'r') as stream: with open("./vinetrimmer/config/Services/amazon.yml", 'r') as stream:
self.config = yaml.safe_load(stream) self.config = yaml.safe_load(stream)
self.region: dict[str, str] = {} self.region: dict[str, str] = {}
self.endpoints: dict[str, str] = {} self.endpoints: dict[str, str] = {}