logo

youtube-dl

[mirror] Download/Watch videos from video hosters
commit: c3cfea906869e8358652e382679a5996c2aec73e
parent 22cb94902f5bbe32d636009c2599eae7aa66282c
Author: Sergey M․ <dstftw@gmail.com>
Date:   Fri, 24 Jan 2020 04:09:10 +0700

[youtube] Fix sigfunc name extraction (closes #23819)

Diffstat:

Myoutube_dl/extractor/youtube.py1+
1 file changed, 1 insertion(+), 0 deletions(-)

diff --git a/youtube_dl/extractor/youtube.py b/youtube_dl/extractor/youtube.py @@ -1343,6 +1343,7 @@ class YoutubeIE(YoutubeBaseInfoExtractor): funcname = self._search_regex( (r'\b[cs]\s*&&\s*[adf]\.set\([^,]+\s*,\s*encodeURIComponent\s*\(\s*(?P<sig>[a-zA-Z0-9$]+)\(', r'\b[a-zA-Z0-9]+\s*&&\s*[a-zA-Z0-9]+\.set\([^,]+\s*,\s*encodeURIComponent\s*\(\s*(?P<sig>[a-zA-Z0-9$]+)\(', + r'\b(?P<sig>[a-zA-Z0-9$]{2})\s*=\s*function\(\s*a\s*\)\s*{\s*a\s*=\s*a\.split\(\s*""\s*\)', r'(?P<sig>[a-zA-Z0-9$]+)\s*=\s*function\(\s*a\s*\)\s*{\s*a\s*=\s*a\.split\(\s*""\s*\)', # Obsolete patterns r'(["\'])signature\1\s*,\s*(?P<sig>[a-zA-Z0-9$]+)\(',