diff --git a/yt_dlp/extractor/fptplay.py b/yt_dlp/extractor/fptplay.py index c98b9b0fe..b1dea9d25 100644 --- a/yt_dlp/extractor/fptplay.py +++ b/yt_dlp/extractor/fptplay.py @@ -38,6 +38,7 @@ class FptplayIE(InfoExtractor): 'duration': '2665', }, }] + def _real_extract(self, url): contentId = self._match_id(url) # Need valid cookie with Bearer token, else it won't work @@ -89,6 +90,7 @@ class FptplayIE(InfoExtractor): 'title': res['result']['title_origin'] if res['result']['title_origin'] else res['result']['title_vie'], 'entries': entries, } + def get_api_with_st_token(self, video_id, episode=None): if episode is not None: path = f'/api/v7.1_w/stream/vod/{video_id}/{0 if episode is None else episode}/adaptive_bitrate' @@ -98,6 +100,7 @@ class FptplayIE(InfoExtractor): t = hashlib.md5(f'6ea6d2a4e2d3a4bd5e275401aa086d{timestamp}{path}'.encode()).hexdigest().upper() r = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/' n = [int(f'0x{t[2 * o: 2 * o + 2]}', 16) for o in range(len(t) // 2)] + def convert(e): t = '' n = 0