Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[vimeo] "Unable to extract login token" on username+passworded video #5082

Closed
ConradHughes opened this issue Feb 27, 2015 · 7 comments
Closed

[vimeo] "Unable to extract login token" on username+passworded video #5082

ConradHughes opened this issue Feb 27, 2015 · 7 comments

Comments

@ConradHughes
Copy link

@ConradHughes ConradHughes commented Feb 27, 2015

I've rented a video which I'd like to watch offline, but get the above error when attempting to download using correct (in web browser, at least) credentials. It's associated with a username/password account on Vimeo.

youtube-dl is up-to-date at time of writing, and "works for me" on videos not tied to the account.

Output from --verbose:

[debug] System config: []
[debug] User config: []
[debug] Command-line args: ['--verbose', '-u', u'PRIVATE', '-p', u'PRIVATE', 'https://vimeo.com/ondemand/10298/']
[debug] Encodings: locale UTF-8, fs UTF-8, out utf_8, pref UTF-8
[debug] youtube-dl version 2015.02.26.2
[debug] Python version 2.7.8 - Linux-3.16.0-4-amd64-x86_64-with-debian-8.0
[debug] exe versions: avconv 11.2-6, avprobe 11.2-6, rtmpdump 2.4
[debug] Proxy map: {}
[vimeo] Logging in
ERROR: Unable to extract login token; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type  youtube-dl -U  to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
Traceback (most recent call last):
  File "./youtube-dl/youtube_dl/YoutubeDL.py", line 643, in extract_info
    ie_result = ie.extract(url)
  File "./youtube-dl/youtube_dl/extractor/common.py", line 274, in extract
    self.initialize()
  File "./youtube-dl/youtube_dl/extractor/common.py", line 268, in initialize
    self._real_initialize()
  File "./youtube-dl/youtube_dl/extractor/vimeo.py", line 210, in _real_initialize
    self._login()
  File "./youtube-dl/youtube_dl/extractor/vimeo.py", line 41, in _login
    token = self._search_regex(r'xsrft: \'(.*?)\'', webpage, 'login token')
  File "./youtube-dl/youtube_dl/extractor/common.py", line 547, in _search_regex
    raise RegexNotFoundError('Unable to extract %s' % _name)
RegexNotFoundError: Unable to extract login token; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type  youtube-dl -U  to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.

When I run with --dump-intermediate-pages I get a base64-encoded blob containing HTML interspersed with 8-bit noise (elided to [8-bit-data] below). Also elided a group of four 8-digit hex numbers; the same four are repeated in each of the three HTML stanzas.

 <script>
        if (typeof playerAssetUrls !== 'undefined') {
                            PlayerManager.run(playerAssetUrls);
                    }
    </script>

    <script src="https://f.vimeocdn.com/js_opt/logging_combined.min.js?[8-hex-digits]"></script>
    <script src="https://f.vimeocdn.com/js_opt/global_combined.min.js?[8-hex-digits]"></script>
    <script src="https://f.vimeocdn.com/js_opt/vimeo/classes/utils/emailsuggestion.min.js?[8-hex-digits]"></script>
    <script src="https://f.vimeocdn.com/js_opt/vimeo/controllers/auth.min.js?[8-hex-digits]"></script>

    <script async src="https://sb.scorecardresearch.com/beacon.js"></script>
    <script async src="https://stats.g.doubleclick.net/dc.js"></script>
    <script>
        function onVimeoDomReady(e) {


                PlayerManager.dispatchReadySignals();

                    }

                    if ('addEvent' in window) {
                window.addEvent('domready', onVimeoDomReady);
            }
            else {
                onVimeoDomReady();
            }
            </script>

    </body>
</html>
[8-bit-data]src="https://f.vimeocdn.com/js_opt/vimeo/controllers/player/player_manager.min.js?[8-hex-digits]"></script>
    <script>
        if (typeof playerAssetUrls !== 'undefined') {
                            PlayerManager.run(playerAssetUrls);
                    }
    </script>

    <script src="https://f.vimeocdn.com/js_opt/logging_combined.min.js?[8-hex-digits]"></script>
    <script src="https://f.vimeocdn.com/js_opt/global_combined.min.js?[8-hex-digits]"></script>
    <script src="https://f.vimeocdn.com/js_opt/vimeo/classes/utils/emailsuggestion.min.js?[8-hex-digits]"></script>
    <script src="https://f.vimeocdn.com/js_opt/vimeo/controllers/auth.min.js?[8-hex-digits]"></script>

    <script async src="https://sb.scorecardresearch.com/beacon.js"></script>
    <script async src="https://stats.g.doubleclick.net/dc.js"></script>
    <script>
        function onVimeoDomReady(e) {


                PlayerManager.dispatchReadySignals();

                    }

                    if ('addEvent' in window) {
                window.addEvent('domready', onVimeoDomReady);
            }
            else {
                onVimeoDomReady();
            }
            </script>

    </body>
</html>
[8-bit-data]="https://f.vimeocdn.com/js_opt/vimeo/controllers/player/player_manager.min.js?[8-hex-digits]"></script>
    <script>
        if (typeof playerAssetUrls !== 'undefined') {
                            PlayerManager.run(playerAssetUrls);
                    }
    </script>

    <script src="https://f.vimeocdn.com/js_opt/logging_combined.min.js?[8-hex-digits]"></script>
    <script src="https://f.vimeocdn.com/js_opt/global_combined.min.js?[8-hex-digits]"></script>
    <script src="https://f.vimeocdn.com/js_opt/vimeo/classes/utils/emailsuggestion.min.js?[8-hex-digits]"></script>
    <script src="https://f.vimeocdn.com/js_opt/vimeo/controllers/auth.min.js?[8-hex-digits]"></script>

    <script async src="https://sb.scorecardresearch.com/beacon.js"></script>
    <script async src="https://stats.g.doubleclick.net/dc.js"></script>
    <script>
        function onVimeoDomReady(e) {


                PlayerManager.dispatchReadySignals();

                    }

                    if ('addEvent' in window) {
                window.addEvent('domready', onVimeoDomReady);
            }
            else {
                onVimeoDomReady();
            }
            </script>

    </body>
</html>
@manoynmonic
Copy link

@manoynmonic manoynmonic commented Mar 1, 2015

Same issue, only with a purchased video, not a rented one. Output from --verbose:

C:\Users\redacted\Desktop>youtube-dl.py -u [my username] -p [my password] http
s://vimeo.com/ondemand/debate/119759220 --verbose
[debug] System config: []
[debug] User config: []
[debug] Command-line args: ['-u', u'PRIVATE', '-p', u'PRIVATE', 'https://vimeo.c
om/ondemand/debate/119759220', '--verbose']
[debug] Encodings: locale cp1252, fs mbcs, out cp437, pref cp1252
[debug] youtube-dl version 2015.02.28
[debug] Python version 2.7.8 - Windows-8-6.2.9200
[debug] exe versions: ffmpeg N-66012-g97b8809, ffprobe N-66012-g97b8809
[debug] Proxy map: {}
[vimeo] Logging in
ERROR: Unable to extract login token; please report this issue on https://yt-dl.
org/bug . Make sure you are using the latest version; type youtube-dl -U to up
date. Be sure to call youtube-dl with the --verbose flag and include its complet
e output.
Traceback (most recent call last):
File "C:\Users\redacted\Commands\youtube-dl.py\youtube_dl\YoutubeDL.py", line 643
, in extract_info
ie_result = ie.extract(url)
File "C:\Users\redacted\Commands\youtube-dl.py\youtube_dl\extractor\common.py", l
ine 274, in extract
self.initialize()
File "C:\Users\redacted\Commands\youtube-dl.py\youtube_dl\extractor\common.py", l
ine 268, in initialize
self._real_initialize()
File "C:\Users\redacted\Commands\youtube-dl.py\youtube_dl\extractor\vimeo.py", li
ne 210, in _real_initialize
self._login()
File "C:\Users\redacted\Commands\youtube-dl.py\youtube_dl\extractor\vimeo.py", li
ne 41, in _login
token = self._search_regex(r'xsrft: '(.*?)'', webpage, 'login token')
File "C:\Users\redacted\Commands\youtube-dl.py\youtube_dl\extractor\common.py", l
ine 547, in _search_regex
raise RegexNotFoundError('Unable to extract %s' % _name)
RegexNotFoundError: Unable to extract login token; please report this issue on h
ttps://yt-dl.org/bug . Make sure you are using the latest version; type youtube
-dl -U to update. Be sure to call youtube-dl with the --verbose flag and includ
e its complete output.

@kldavis4
Copy link

@kldavis4 kldavis4 commented Apr 22, 2015

Looks like I am having the same issue with a vimeo video password:

ubuntu@ip-172-30-0-115:~$ youtube-dl --verbose --video-password PASSWORD https://vimeo.com/125472112
[debug] System config: []
[debug] User config: []
[debug] Command-line args: [u'--verbose', u'--video-password', u'PRIVATE', u'https://vimeo.com/125472112']
[debug] Encodings: locale UTF-8, fs UTF-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2015.04.17
[debug] Python version 2.7.6 - Linux-3.13.0-48-generic-x86_64-with-Ubuntu-14.04-trusty
[debug] exe versions: none
[debug] Proxy map: {}
[vimeo] 125472112: Downloading webpage
[vimeo] 125472112: Extracting information
ERROR: Unable to extract login token; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type  youtube-dl -U  to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
Traceback (most recent call last):
  File "/usr/local/bin/youtube-dl/youtube_dl/extractor/vimeo.py", line 273, in _real_extract
    flags=re.DOTALL)
  File "/usr/local/bin/youtube-dl/youtube_dl/extractor/common.py", line 557, in _search_regex
    raise RegexNotFoundError('Unable to extract %s' % _name)
RegexNotFoundError: Unable to extract info section; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type  youtube-dl -U  to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
Traceback (most recent call last):
  File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 651, in extract_info
    ie_result = ie.extract(url)
  File "/usr/local/bin/youtube-dl/youtube_dl/extractor/common.py", line 275, in extract
    return self._real_extract(url)
  File "/usr/local/bin/youtube-dl/youtube_dl/extractor/vimeo.py", line 282, in _real_extract
    self._verify_video_password(url, video_id, webpage)
  File "/usr/local/bin/youtube-dl/youtube_dl/extractor/vimeo.py", line 180, in _verify_video_password
    token = self._search_regex(r'xsrft = \'(.*?)\'', webpage, 'login token')
  File "/usr/local/bin/youtube-dl/youtube_dl/extractor/common.py", line 557, in _search_regex
    raise RegexNotFoundError('Unable to extract %s' % _name)
RegexNotFoundError: Unable to extract login token; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type  youtube-dl -U  to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
@ghost ghost closed this in 7513f29 Apr 22, 2015
@dstftw
Copy link
Collaborator

@dstftw dstftw commented Apr 26, 2015

This has been fixed in youtube-dl 2015.04.26. See our FAQ if you have problems updating.

@rnoremacc
Copy link

@rnoremacc rnoremacc commented Apr 28, 2015

Hi,
Sorry, but I still have the same error occurring after the the 2015-04-26 update.
I've tried it on Lubuntu 14.10 and 15.04.
Both these Portuguese TV show episodes are blocked on Youtube and the back up copies with passwords are on Vimeo.
First is vimeo.com/safelight/38 with password 38secrets.
Second is vimeo.com/safelight/39 with password 39out.
Both play correctly from vimeo in Chrome.

chris@zbox3:~$ youtube-dl -i --write-sub --sub-lang en --convert-subtitles srt --video-password 39out vimeo.com/safelight/39 --verbose
[debug] System config: []
[debug] User config: []
[debug] Command-line args: [u'-i', u'--write-sub', u'--sub-lang', u'en', u'--convert-subtitles', u'srt', u'--video-password', u'PRIVATE', u'vimeo.com/safelight/39', u'--verbose']
[debug] Encodings: locale UTF-8, fs UTF-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2015.04.26
[debug] Python version 2.7.8 - Linux-3.16.0-28-generic-x86_64-with-Ubuntu-14.10-utopic
[debug] exe versions: avconv 11-6, avprobe 11-6
[debug] Proxy map: {}
WARNING: The url doesn't specify the protocol, trying with http
[vimeo] 39: Downloading webpage
[vimeo] 39: Extracting information
ERROR: Unable to extract login token; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type youtube-dl -U to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
Traceback (most recent call last):
File "/usr/local/bin/youtube-dl/youtube_dl/extractor/vimeo.py", line 273, in _real_extract
flags=re.DOTALL)
File "/usr/local/bin/youtube-dl/youtube_dl/extractor/common.py", line 558, in _search_regex
raise RegexNotFoundError('Unable to extract %s' % _name)
RegexNotFoundError: Unable to extract info section; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type youtube-dl -U to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
Traceback (most recent call last):
File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 651, in extract_info
ie_result = ie.extract(url)
File "/usr/local/bin/youtube-dl/youtube_dl/extractor/common.py", line 276, in extract
return self._real_extract(url)
File "/usr/local/bin/youtube-dl/youtube_dl/extractor/vimeo.py", line 282, in _real_extract
self._verify_video_password(url, video_id, webpage)
File "/usr/local/bin/youtube-dl/youtube_dl/extractor/vimeo.py", line 180, in _verify_video_password
token = self._search_regex(r'xsrft":"(.*?)"', webpage, 'login token')
File "/usr/local/bin/youtube-dl/youtube_dl/extractor/common.py", line 558, in _search_regex
raise RegexNotFoundError('Unable to extract %s' % _name)
RegexNotFoundError: Unable to extract login token; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type youtube-dl -U to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.

In Chrome, the vimeo page redirects to https://vimeo.com/125285780.
I get the same error if I use this as the starting URL.

Regards,
Chris.

jaimeMF added a commit that referenced this issue Apr 28, 2015
Since they have changed again to the previous format, I've modified the regex to match both formats.
@jaimeMF
Copy link
Collaborator

@jaimeMF jaimeMF commented Apr 28, 2015

@rnoremacc I think the password protected should work again with 2edce52, which will be included in the next version.

@rnoremacc
Copy link

@rnoremacc rnoremacc commented Apr 28, 2015

@jaimeMF Thank you for the quick response, unfortunately the 2015-04-28 version fails the same way.
Not sure if this is the "next version" you mentioned.
I've also tried accessing directly from Australia (where I am) and also via a VPN exiting through the Netherlands, with the same results each time.

@leotulipan
Copy link

@leotulipan leotulipan commented Aug 10, 2015

@jaimeMF This issue popped up again for me as well with a rented video from vimeo (ID changed to a generic one)

youtube-dl.exe --verbose -u myuser@gmail.com https://vimeo.com/55500033
[debug] System config: []
[debug] User config: []
[debug] Command-line args: ['--verbose', '-u', 'PRIVATE', 'https://vimeo.com/55500033']
Type account password and press [Return]:
[debug] Encodings: locale cp1252, fs mbcs, out cp850, pref cp1252
[debug] youtube-dl version 2015.08.09
[debug] Python version 3.4.3 - Windows-8-6.2.9200
[debug] exe versions: none
[debug] Proxy map: {}
[vimeo] Logging in
ERROR: Unable to extract login token; please report this issue on https://yt-dl.org/bug . Make sure you
are using the latest version; see https://yt-dl.org/update on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
Traceback (most recent call last):
File "C:\Python34\lib\site-packages\youtube_dl\YoutubeDL.py", line 655, in extract_info
ie_result = ie.extract(url)
File "C:\Python34\lib\site-packages\youtube_dl\extractor\common.py", line 285, in extract
self.initialize()
File "C:\Python34\lib\site-packages\youtube_dl\extractor\common.py", line 279, in initialize
self._real_initialize()
File "C:\Python34\lib\site-packages\youtube_dl\extractor\vimeo.py", line 225, in _real_initialize
self._login()
File "C:\Python34\lib\site-packages\youtube_dl\extractor\vimeo.py", line 42, in _login
token = self._search_regex(r'xsrft":"(.*?)"', webpage, 'login token')
File "C:\Python34\lib\site-packages\youtube_dl\extractor\common.py", line 568, in _search_regex
raise RegexNotFoundError('Unable to extract %s' % _name)
youtube_dl.utils.RegexNotFoundError: Unable to extract login token; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see https://yt-dl.org/update on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
7 participants
You can’t perform that action at this time.