mirror of
				https://github.com/ytdl-org/youtube-dl.git
				synced 2025-10-29 09:26:20 -07:00 
			
		
		
		
	[kaltura] Fix service URL extraction (closes #22658)
This commit is contained in:
		| @@ -155,11 +155,11 @@ class KalturaIE(InfoExtractor): | |||||||
|                     embed_info[k] = v.strip() |                     embed_info[k] = v.strip() | ||||||
|             url = 'kaltura:%(partner_id)s:%(id)s' % embed_info |             url = 'kaltura:%(partner_id)s:%(id)s' % embed_info | ||||||
|             escaped_pid = re.escape(embed_info['partner_id']) |             escaped_pid = re.escape(embed_info['partner_id']) | ||||||
|             service_url = re.search( |             service_mobj = re.search( | ||||||
|                 r'<script[^>]+src=["\']((?:https?:)?//.+?)/p/%s/sp/%s00/embedIframeJs' % (escaped_pid, escaped_pid), |                 r'<script[^>]+src=(["\'])(?P<id>(?:https?:)?//(?:(?!\1).)+)/p/%s/sp/%s00/embedIframeJs' % (escaped_pid, escaped_pid), | ||||||
|                 webpage) |                 webpage) | ||||||
|             if service_url: |             if service_mobj: | ||||||
|                 url = smuggle_url(url, {'service_url': service_url.group(1)}) |                 url = smuggle_url(url, {'service_url': service_mobj.group('id')}) | ||||||
|             return url |             return url | ||||||
|  |  | ||||||
|     def _kaltura_api_call(self, video_id, actions, service_url=None, *args, **kwargs): |     def _kaltura_api_call(self, video_id, actions, service_url=None, *args, **kwargs): | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user