1
0
mirror of https://github.com/l1ving/youtube-dl synced 2020-11-18 19:53:54 -08:00

[safari] Fix authentication

Fix issue #22161
This commit is contained in:
phan-ctrl 2019-08-22 17:19:55 +07:00 committed by GitHub
parent 393cc31d5e
commit b9b34b70d2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -71,6 +71,10 @@ class SafariBaseIE(InfoExtractor):
# oreilly serves two same groot_sessionid cookies in Set-Cookie header
# and expects first one to be actually set
self._apply_first_set_cookie_header(urlh, 'groot_sessionid')
# Fix issue #22161
# We need 2 more cookies to be able to login to oreilly
self._apply_first_set_cookie_header(urlh, 'orm-jwt')
self._apply_first_set_cookie_header(urlh, 'orm-rt')
_, urlh = self._download_webpage_handle(
auth.get('redirect_uri') or next_uri, None, 'Completing login',)