bbolli / tumblr-utils

Utilities for dealing with Tumblr blogs, Tumblr backup
GNU General Public License v3.0
667 stars 124 forks source link

Possible SSL error? #213

Closed lawyernobaka closed 4 years ago

lawyernobaka commented 4 years ago

Hello All,

I'm definitely a layperson when it comes to utilities like this, so any help that can be provided is appreciated. If this is not the forum to ask for this kind of help, please let me know.

I finally got around to requesting my own API key following the changeover in late June, but now when I attempt to backup any Tumblr blog, this message displays for all attempted media downloads:

<urlopen error [Errno 1] _ssl.c:499: error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version> downloading

The image/media URL follows the end of this error.

I'm still able to backup all posts to .html files still but media cannot be downloaded. Any ideas why this might be?

I tried using both an older download of tumblr-utils as well as a fresh download from today, 8/4/2020. I also attempted to backup multiple blogs from multiple users to rule out blog-specific issues.

Thanks for your help!

cebtenzzre commented 4 years ago

What OS are you using, and what is your Python version? (python --version) It looks like your Python interpreter is built against an old version of OpenSSL, so the server is rejecting the connection for security reasons. If this is on macOS, there are ways the code can work around this - see what pip does (requires urllib3). But you might also be able to just avoid the system Python and OpenSSL (e.g. using homebrew).

lawyernobaka commented 4 years ago

That command isn't generating anything, but, to the best of my knowledge, I'm running Python version 2.7. And I'm (regretfully) running Windows 10 Home, Build 18363.959.

Based on what you're saying and the documentation you provided, it sounds like I should try updating OpenSSL.

cebtenzzre commented 4 years ago

@lawyernobaka See if you can update to the latest version of Python 2.7. There's a chance you have a version from as long as 10 years ago. Trying to update just OpenSSL won't get you very far, because AFAIK Python 2.7 for Windows is statically linked to OpenSSL. That means it's built into the interpreter and cannot be updated without also updating Python. At the very least, Python should ship with and use its own version of OpenSSL, so if you have a recent version of Python you should have a recent version of OpenSSL.

lawyernobaka commented 4 years ago

@Cebtenzzre That did it. Had to do a fresh install and update PATH while I was at it, but that worked. Thank you very much for your help!