Skip to content

Commit 6349684

Browse files
Remove deprecated repo (#634)
1 parent 86a1bff commit 6349684

File tree

2 files changed

+2
-30
lines changed

2 files changed

+2
-30
lines changed

lib/inputstreamhelper/config.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -71,10 +71,6 @@
7171
'webOS': '21.1'
7272
}
7373

74-
WIDEVINE_VERSIONS_URL = 'https://dl.google.com/widevine-cdm/versions.txt'
75-
76-
WIDEVINE_DOWNLOAD_URL = 'https://dl.google.com/widevine-cdm/{version}-{os}-{arch}.zip'
77-
7874
WIDEVINE_LICENSE_FILE = 'LICENSE'
7975

8076
WIDEVINE_MANIFEST_FILE = 'manifest.json'

lib/inputstreamhelper/widevine/repo.py

Lines changed: 2 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,7 @@
55
import json
66
import random
77

8-
from .. import config
9-
from ..kodiutils import log
10-
from ..utils import arch, http_get, http_head, http_post, system_os
8+
from ..utils import arch, http_post, system_os
119

1210

1311
def cdm_from_repo():
@@ -18,28 +16,6 @@ def cdm_from_repo():
1816
return False
1917

2018

21-
def widevines_available_from_repo():
22-
"""Returns all available Widevine CDM versions and urls from Google's library CDM repository"""
23-
cdm_versions = http_get(config.WIDEVINE_VERSIONS_URL).strip('\n').split('\n')
24-
try:
25-
cdm_os = config.WIDEVINE_OS_MAP[system_os()]
26-
cdm_arch = config.WIDEVINE_ARCH_MAP_REPO[arch()]
27-
except KeyError:
28-
cdm_os = "mac"
29-
cdm_arch = "x64"
30-
available_cdms = []
31-
for cdm_version in cdm_versions:
32-
cdm_url = config.WIDEVINE_DOWNLOAD_URL.format(version=cdm_version, os=cdm_os, arch=cdm_arch)
33-
http_status = http_head(cdm_url)
34-
if http_status == 200:
35-
available_cdms.append({'version': cdm_version, 'url': cdm_url})
36-
37-
if not available_cdms:
38-
log(4, "could not find any available cdm in repo")
39-
40-
return available_cdms
41-
42-
4319
def latest_widevine_available_from_repo(cdm_os, cdm_arch):
4420
"""Returns the latest available Widevine CDM version and url from Google's library CDM repository"""
4521
cdm = {}
@@ -69,7 +45,7 @@ def latest_widevine_available_from_repo(cdm_os, cdm_arch):
6945
'platform': cdm_os,
7046
},
7147
'protocol': '4.0',
72-
'updaterversion': '140.0.7339.127'
48+
'updaterversion': '142.0.7444.175'
7349
}
7450
}
7551
text = http_post(url, data=json.dumps(payload).encode('utf-8'), headers=headers)

0 commit comments

Comments
 (0)