diff options
author | Sergey M․ <dstftw@gmail.com> | 2018-02-05 23:41:55 +0700 |
---|---|---|
committer | Sergey M․ <dstftw@gmail.com> | 2018-02-05 23:56:00 +0700 |
commit | 240f26229d2ef655a6d16e067094a24ab77bce29 (patch) | |
tree | 2a1f70114fca36cf92fa9b916ba83d75f5d9c77a /youtube_dl/extractor | |
parent | b9b150def75640f12c714762bb572f9a4757d969 (diff) |
[extractor/common] Respect secure schemes in _extract_wowza_formats
Diffstat (limited to 'youtube_dl/extractor')
-rw-r--r-- | youtube_dl/extractor/common.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/youtube_dl/extractor/common.py b/youtube_dl/extractor/common.py index 988fc15ff..ff62b5cf3 100644 --- a/youtube_dl/extractor/common.py +++ b/youtube_dl/extractor/common.py @@ -2250,9 +2250,10 @@ class InfoExtractor(object): def _extract_wowza_formats(self, url, video_id, m3u8_entry_protocol='m3u8_native', skip_protocols=[]): query = compat_urlparse.urlparse(url).query url = re.sub(r'/(?:manifest|playlist|jwplayer)\.(?:m3u8|f4m|mpd|smil)', '', url) - url_base = self._search_regex( - r'(?:(?:https?|rtmp|rtsp):)?(//[^?]+)', url, 'format url') - http_base_url = '%s:%s' % ('http', url_base) + mobj = re.search( + r'(?:(?:http|rtmp|rtsp)(?P<s>s)?:)?(?P<url>//[^?]+)', url) + url_base = mobj.group('url') + http_base_url = '%s%s:%s' % ('http', mobj.group('s') or '', url_base) formats = [] def manifest_url(manifest): |