REPOST: Re: SSL Sockets in Windows

Syver Enstad syver-en+usenet at
Sat Dec 29 10:03:16 EST 2001

Gerhard Häring <gh_pythonlist at> writes:

> Le 28/12/01 à 07:18, Syver Enstad écrivit:
> > 
> > Hi Al, I'm not exactly an expert on SSL :-). I know it's what goes
> on
> > behind the scenes when my browser uses an https url and
> communication
> > is encrypted and whatnot. 
> > 
> > Do you have (or can you refer me to) a quick
> > example to check that SSL is indeed working on Python?
> You can check pretty easily if your Python is compiled with SSL
> support:
>     'ssl' in dir(socket)

Yes, returns true (1)

> If so, you should be able to fetch a HTML page with the urllib module:
>     print urllib.urlopen("").read()

Yes, this fetches the front page of sourceforge, which says that I'm
not logged in.

What would happen if I didn't have SSL installed. 

You see I compiled up a new version of _socket.pyd with VC++ 6 and
this time I specified that SSL shouldn't be compiled in. 'ssl' in
dir(socket) still returns true, and the download goes without a
hitch too. I haven't checked with a packet sniffer though.

> reduce(lambda x,y:x+y,map(lambda
> x:chr(ord(x)^42),tuple('zS^BED\nX_FOY\x0b')))

Cute, and true.


Vennlig hilsen 

Syver Enstad

========= WAS CANCELLED BY =======:
From: Syver Enstad <syver-en+usenet at>
Newsgroups: comp.lang.python
Subject: cmsg cancel <u666qkr0r.fsf at>
Control: cancel <u666qkr0r.fsf at>
Date: Mon, 31 Dec 2001 02:12:08 GMT
Organization: A poorly-installed InterNetNews site
Lines: 2
Message-ID: <cancel.u666qkr0r.fsf at>
X-Trace: 1009774749 27193 (31 Dec 2001 04:59:09 GMT)
X-Complaints-To: usenet at
NNTP-Posting-Date: Mon, 31 Dec 2001 04:59:09 +0000 (UTC)
X-No-Archive: yes
X-Unac4ncel: yes
X-Commentary: I love NewsAgent 1.10 and the Sandblaster Cancel Engine Build 74 (19 March 1999)

This message was cancelled from within Mozilla.

More information about the Python-list mailing list