From 5ebaa40ed2f1e5281615afc7b5134715cdada231 Mon Sep 17 00:00:00 2001 From: Pablo Hoffman Date: Thu, 15 Nov 2012 16:28:39 -0200 Subject: [PATCH] changed SSL version to use from SSLv23 to TLSv1. closes #194 but needs more testing against counter-effects --- scrapy/core/downloader/webclient.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/scrapy/core/downloader/webclient.py b/scrapy/core/downloader/webclient.py index 985cc4ae5..b75af5ce4 100644 --- a/scrapy/core/downloader/webclient.py +++ b/scrapy/core/downloader/webclient.py @@ -151,6 +151,11 @@ class ScrapyClientContextFactory(ClientContextFactory): # see https://github.com/scrapy/scrapy/issues/82 # and https://github.com/scrapy/scrapy/issues/26 + def __init__(self): + # see this issue on why we use TLSv1_METHOD by default + # https://github.com/scrapy/scrapy/issues/194 + self.method = SSL.TLSv1_METHOD + def getContext(self): ctx = ClientContextFactory.getContext(self) # Enable all workarounds to SSL bugs as documented by