1
0
mirror of https://github.com/yt-dlp/yt-dlp.git synced 2025-09-13 23:28:29 +00:00

fix overly permissive regex

This commit is contained in:
frank 2025-06-30 12:19:23 -05:00
parent 889992f631
commit dd21959466

View File

@ -28,13 +28,13 @@ def _real_extract(self, url):
'partner_id', 'partner_id',
) )
entry_id = self._html_search_regex( entry_id = self._html_search_regex(
r'const kentryID = \'([0-9A-z]+)\';', r'const kentryID = \'([0-9A-z]{10})\';',
webpage, webpage,
'kentry_id', 'kentry_id',
) )
kaltura_api_response = self._get_video_info(entry_id, partner_id) kaltura_api_response = self._get_video_info(entry_id, partner_id)
kaltura_id = self._search_regex( kaltura_id = self._search_regex(
r'http://cdnapi.kaltura.com/p/[0-9]+/sp/[0-9]+/playManifest/entryId/([0-9A-z]+)/format/url/protocol/http', r'http://cdnapi.kaltura.com/p/[0-9]+/sp/[0-9]+/playManifest/entryId/([0-9A-z]{10})/format/url/protocol/http',
kaltura_api_response[1].get('dataUrl'), kaltura_api_response[1].get('dataUrl'),
'kaltura_id', 'kaltura_id',
) )