Add Amazon scheme

This commit is contained in:
FoxRefire 2024-05-05 17:35:55 +09:00
parent 35072602c7
commit 48cfbc6dc2
3 changed files with 10 additions and 0 deletions

View File

@ -34,6 +34,7 @@
<label for="scheme">Challenge scheme</label>
<select id="scheme">
<option value="CommonWV">CommonWV</option>
<option value="Amazon">Amazon</option>
<option value="Comcast">Comcast Xfinity</option>
<option value="DRMToday">DRMToday</option>
<option value="GlobalTV">GlobalTV</option>

8
python/schemes/Amazon.py Normal file
View File

@ -0,0 +1,8 @@
import urllib.parse
from pyodide.ffi import to_js
payload = f"widevine2Challenge={urllib.parse.quote(base64.b64encode(challenge).decode())}&includeHdcpTestKeyInLicense=true"
res = await js.corsFetch(licUrl, "POST", to_js(licHeaders), payload)
res = json.loads(base64.b64decode(res.encode()).decode())
licence = base64.b64decode(res['widevine2License']['license'].encode())

View File

@ -6,6 +6,7 @@ lic.drmtoday.com$$DRMToday
corusappservices.com/authorization/widevine/getresourcekey$$GlobalTV
b2c-www.redefine.pl/rpc/drm$$Polsat
widevine.entitlement.eu.theplatform.com$$thePlatform
cdp/catalog/GetPlaybackResources$$Amazon
contentlicenseservice/v1/licenses
media-license-server/validate-auth-token
wv-keyos.licensekeyserver