<s> from OpenSSL import SSL <EOL> from twisted . internet . ssl import ClientContextFactory <EOL> class ScrapyClientContextFactory ( ClientContextFactory ) : <EOL> "<STR_LIT>" <EOL> def __init__ ( self ) : <EOL> self . method = SSL . TLSv1_METHOD <EOL> def getContext ( self , hostname = None , port = None ) : <EOL> ctx = ClientContextFactory . getContext ( self ) <EOL> ctx . set_options ( SSL . OP_ALL ) <EOL> return ctx </s>
