aboutsummaryrefslogtreecommitdiffstats
path: root/youtube_dl/extractor/brightcove.py
diff options
context:
space:
mode:
authorRogério Brito <rbrito@ime.usp.br>2017-03-30 15:27:10 -0300
committerRogério Brito <rbrito@ime.usp.br>2017-03-30 15:27:10 -0300
commitabc36f0474141930338eef35e2444365fab932b6 (patch)
treeb3d6bde538fb42690f721a01376391ece8218aa3 /youtube_dl/extractor/brightcove.py
parent1d3fd83f473663fce3e0a10303473a38d80cc3d0 (diff)
downloadyoutube-dl-abc36f0474141930338eef35e2444365fab932b6.zip
youtube-dl-abc36f0474141930338eef35e2444365fab932b6.tar.gz
youtube-dl-abc36f0474141930338eef35e2444365fab932b6.tar.bz2
New upstream version 2017.03.26
Diffstat (limited to 'youtube_dl/extractor/brightcove.py')
-rw-r--r--youtube_dl/extractor/brightcove.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/youtube_dl/extractor/brightcove.py b/youtube_dl/extractor/brightcove.py
index 66c8cb2..46ef8e6 100644
--- a/youtube_dl/extractor/brightcove.py
+++ b/youtube_dl/extractor/brightcove.py
@@ -193,7 +193,13 @@ class BrightcoveLegacyIE(InfoExtractor):
if videoPlayer is not None:
if isinstance(videoPlayer, list):
videoPlayer = videoPlayer[0]
- if not (videoPlayer.isdigit() or videoPlayer.startswith('ref:')):
+ videoPlayer = videoPlayer.strip()
+ # UUID is also possible for videoPlayer (e.g.
+ # http://www.popcornflix.com/hoodies-vs-hooligans/7f2d2b87-bbf2-4623-acfb-ea942b4f01dd
+ # or http://www8.hp.com/cn/zh/home.html)
+ if not (re.match(
+ r'^(?:\d+|[\da-fA-F]{8}-?[\da-fA-F]{4}-?[\da-fA-F]{4}-?[\da-fA-F]{4}-?[\da-fA-F]{12})$',
+ videoPlayer) or videoPlayer.startswith('ref:')):
return None
params['@videoPlayer'] = videoPlayer
linkBase = find_param('linkBaseURL')