Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
user234683 committed Sep 7, 2018
1 parent 5f4d4e0 commit 0cb96b1
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion youtube_dl/extractor/youtube.py
Original file line number Diff line number Diff line change
Expand Up @@ -1180,7 +1180,9 @@ def _genslice(start, end, step):
def _parse_sig_js(self, jscode):
funcname = self._search_regex(
(r'(["\'])signature\1\s*,\s*(?P<sig>[a-zA-Z0-9$]+)\(',
r'\.sig\|\|(?P<sig>[a-zA-Z0-9$]+)\('),
r'\.sig\|\|(?P<sig>[a-zA-Z0-9$]+)\(',
r'yt\.akamaized\.net/\)\s*\|\|\s*.*?\s*c\s*&&\s*d\.set\([^,]+\s*,\s*(?P<sig>[a-zA-Z0-9$]+)\(',
r'\bc\s*&&\s*d\.set\([^,]+\s*,\s*(?P<sig>[a-zA-Z0-9$]+)\('),
jscode, 'Initial JS player signature function name', group='sig')

jsi = JSInterpreter(jscode)
Expand Down

0 comments on commit 0cb96b1

Please sign in to comment.