Skip to content

Commit

Permalink
[youtube] Add another JS signature function name regex (closes #18091,
Browse files Browse the repository at this point in the history
…closes #18093, closes #18094)
  • Loading branch information
dstftw committed Nov 7, 2018
1 parent 0df514f commit 2511eee
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion youtube_dl/extractor/youtube.py
Original file line number Diff line number Diff line change
Expand Up @@ -1192,7 +1192,8 @@ def _parse_sig_js(self, jscode):
(r'(["\'])signature\1\s*,\s*(?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$]+)\('),
r'\bc\s*&&\s*d\.set\([^,]+\s*,\s*(?P<sig>[a-zA-Z0-9$]+)\(',
r'\bc\s*&&\s*d\.set\([^,]+\s*,\s*\([^)]*\)\s*\(\s*(?P<sig>[a-zA-Z0-9$]+)\('),
jscode, 'Initial JS player signature function name', group='sig')

jsi = JSInterpreter(jscode)
Expand Down

1 comment on commit 2511eee

@5UFKEFU
Copy link

@5UFKEFU 5UFKEFU commented on 2511eee Jan 8, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

希望它不要经常改。

Please sign in to comment.