Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #90215

Re: SSL Socket Error

Path csiph.com!usenet.pasdenom.info!news.redatomik.org!newsfeed.xs4all.nl!newsfeed2.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail
Return-Path <python-python-list@m.gmane.org>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.001
X-Spam-Evidence '*H*': 1.00; '*S*': 0.00; 'error:': 0.07; 'paths': 0.07; 'subject:Error': 0.07; 'exception,': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'skip:# 30': 0.09; 'url:github': 0.09; 'runs': 0.10; 'python': 0.11; "(i'm": 0.16; 'expects': 0.16; 'luck,': 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'skip:[ 30': 0.16; 'skip:[ 40': 0.16; 'skip:[ 50': 0.16; 'subject:SSL': 0.16; 'undefined.': 0.16; 'exception': 0.16; 'wrote:': 0.18; 'file,': 0.19; 'seems': 0.21; 'header:User-Agent:1': 0.23; 'config': 0.24; 'own.': 0.24; 'ssl': 0.24; 'server.': 0.24; 'looks': 0.24; 'login': 0.25; 'certain': 0.27; 'defined': 0.27; 'header:X-Complaints-To:1': 0.27; 'specified': 0.30; 'included': 0.31; 'code': 0.31; 'file': 0.32; 'running': 0.33; 'entirely': 0.33; 'connection': 0.35; 'operations': 0.35; 'but': 0.35; 'should': 0.36; 'project': 0.37; 'server': 0.38; 'to:addr:python-list': 0.38; 'channel': 0.39; 'to:addr:python.org': 0.39; 'received:org': 0.40; 'how': 0.40; 'blank': 0.60; 'numbers': 0.61; 'email addr:gmail.com': 0.63; 'sample': 0.67; 'header:Reply-To:1': 0.67; 'default': 0.69; 'reply-to:no real name:2**0': 0.71; 'incoming': 0.72; 'listening': 0.74; 'reply-to:addr:gmail.com': 0.80; 'examining': 0.84
X-Injected-Via-Gmane http://gmane.org/
To python-list@python.org
From Kev Dwyer <kevin.p.dwyer@gmail.com>
Subject Re: SSL Socket Error
Date Sat, 09 May 2015 08:00:27 +0100
References <b8712610-2956-4954-83dd-cdc83498f5ab@googlegroups.com>
Reply-To kevin.p.dwyer@gmail.com
Mime-Version 1.0
Content-Type text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding 7Bit
X-Gmane-NNTP-Posting-Host cpc5-hari13-2-0-cust222.20-2.cable.virginm.net
Mail-Copies-To kevin.p.dwyer@gmail.com
User-Agent KNode/4.14.6
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.20+
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.274.1431154854.12865.python-list@python.org> (permalink)
Lines 39
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1431154854 news.xs4all.nl 2849 [2001:888:2000:d::a6]:43002
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:90215

Show key headers only | View raw


shdwkeeper@gmail.com wrote:

> Ive setup a Debian server with Python 2.7.9.  Have everything running and
> SSL as well, but when I try and login to using HTTPS:// I get this error:
> 
> Incoming web connection from ('192.168.15.177', 53202)
> error: uncaptured python exception, closing channel <main.AlarmServer
> listening :8111 at 0x75ea7b48> (:certfile must be specified for
> server-side operations [/usr/lib/python2.7/asyncore.py|read|83]
> [/usr/lib/python2.7/asyncore.py|handle_read_event|443]
> [./alarmserver.py|handle_accept|456]
> [/usr/lib/python2.7/ssl.py|wrap_socket|891]
> [/usr/lib/python2.7/ssl.py|init|498])
> 
> Any ideas how to resolve?

It looks like the exception is coming up through alarmserver.py, which seems 
to be based on https://github.com/juggie/AlarmServer (I'm not entirely
certain because the line numbers don't seem to match).  Anyway, looking at 
the code for alarmserver.py it expects to find certificate paths defined in
its config file, but they are undefined.

The sample config file for the project includes this section:

## The server runs with SSL. You need a certificate and key
## server.crt and server.key are included but you should 
## generate your own.
## If left blank the default included cert/key will be used
#certfile=/etc/apache2/ssl/server.crt
#keyfile=/etc/apache2/ssl/server.key
certfile=
keyfile=

So I think you need to start by examining the config file on your server.

Good luck,

Kev

Back to comp.lang.python | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

SSL Socket Error shdwkeeper@gmail.com - 2015-05-08 22:46 -0700
  Re: SSL Socket Error Kev Dwyer <kevin.p.dwyer@gmail.com> - 2015-05-09 08:00 +0100

csiph-web