Bug 839840 - CherryPy 3.2.1 contains bug that breaks SSL WSGI server
CherryPy 3.2.1 contains bug that breaks SSL WSGI server
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: python-cherrypy (Show other bugs)
16
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Luke Macken
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-07-12 22:35 EDT by Chris St. Pierre
Modified: 2016-09-19 22:43 EDT (History)
5 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-07-27 21:22:20 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Chris St. Pierre 2012-07-12 22:35:26 EDT
Description of problem:

CherryPy 3.2.1 contains a bug that breaks the SSL WSGI server.

Version-Release number of selected component (if applicable):

3.2.1-1

How reproducible:

Always.

Steps to Reproduce:
1.

import cherrypy

class Root:
    pass

cherrypy.quickstart(Core(),
                    config={'global': 
                            {'server.ssl_certificate':
                                 '/etc/pki/tls/certs/localhost.crt'}})


Actual results:

[12/Jul/2012:22:33:49] ENGINE Listening for SIGHUP.                                                                                  |
[12/Jul/2012:22:33:49] ENGINE Listening for SIGTERM.                                                                                 |
[12/Jul/2012:22:33:49] ENGINE Listening for SIGUSR1.                                                                                 |
[12/Jul/2012:22:33:49] ENGINE Bus STARTING                                                                                           |
[12/Jul/2012:22:33:49] ENGINE Started monitor thread 'Autoreloader'.                                                                 |
[12/Jul/2012:22:33:49] ENGINE Started monitor thread '_TimeoutMonitor'.                                                              |
[12/Jul/2012:22:33:49] ENGINE Error in 'start' listener <bound method Server.start of <cherrypy._cpserver.Server object at 0x1208610>|
>                                                                                                                                    |
Traceback (most recent call last):                                                                                                   |
  File "/usr/lib/python2.7/site-packages/cherrypy/process/wspbus.py", line 197, in publish                                           |
    output.append(listener(*args, **kwargs))                                                                                         |
  File "/usr/lib/python2.7/site-packages/cherrypy/_cpserver.py", line 150, in start                                                  |
    self.httpserver, self.bind_addr = self.httpserver_from_self()                                                                    |
  File "/usr/lib/python2.7/site-packages/cherrypy/_cpserver.py", line 141, in httpserver_from_self                                   |
    httpserver = _cpwsgi_server.CPWSGIServer(self)                                                                                   |
  File "/usr/lib/python2.7/site-packages/cherrypy/_cpwsgi_server.py", line 53, in __init__                                           |
    adapter_class = wsgiserver.get_ssl_adapter_class(ssl_module)                                                                     |
AttributeError: 'module' object has no attribute 'get_ssl_adapter_class'                                                             |
                                                                                                                                     |
[12/Jul/2012:22:33:49] ENGINE Shutting down due to error in start listener:                                                          |
Traceback (most recent call last):                                                                                                   |
  File "/usr/lib/python2.7/site-packages/cherrypy/process/wspbus.py", line 235, in start                                             |
    self.publish('start')                                                                                                            |
  File "/usr/lib/python2.7/site-packages/cherrypy/process/wspbus.py", line 215, in publish                                           |
    raise exc                                                                                                                        |
ChannelFailures: AttributeError("'module' object has no attribute 'get_ssl_adapter_class'",)

[12/Jul/2012:22:33:49] ENGINE Bus STOPPING
[12/Jul/2012:22:33:49] ENGINE HTTP Server None already shut down
[12/Jul/2012:22:33:49] ENGINE Stopped thread '_TimeoutMonitor'.
[12/Jul/2012:22:33:49] ENGINE Stopped thread 'Autoreloader'.
[12/Jul/2012:22:33:49] ENGINE Bus STOPPED
[12/Jul/2012:22:33:49] ENGINE Bus EXITING
[12/Jul/2012:22:33:49] ENGINE Bus EXITED

Expected results:

CherryPy server starts.

Additional info:

I've made the example deliberately minimal; it doesn't change anything if you give an SSLAdapter or key or anything like that.  The bug happens while the WSGI server is being instantiated, before it even gets a chance to start SSL.
Comment 1 Chris St. Pierre 2012-07-12 22:35:52 EDT
Bug is fixed in https://bitbucket.org/cherrypy/cherrypy/changeset/faaaef5002f4
Comment 2 Toshio Ernie Kuratomi 2012-07-13 16:39:27 EDT
Cherrypy-3.2.2 contains that fix.  We have that built for f17.  I've pushed a build of that out for F16 now as well.  If you could test and leave karma in bodhi (the updates system) when it hits the repository, that would be great.
Comment 3 Fedora Update System 2012-07-13 16:41:08 EDT
python-cherrypy-3.2.2-2.fc16 has been submitted as an update for Fedora 16.
https://admin.fedoraproject.org/updates/python-cherrypy-3.2.2-2.fc16
Comment 4 Fedora Update System 2012-07-14 17:54:38 EDT
Package python-cherrypy-3.2.2-2.fc16:
* should fix your issue,
* was pushed to the Fedora 16 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing python-cherrypy-3.2.2-2.fc16'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2012-10630/python-cherrypy-3.2.2-2.fc16
then log in and leave karma (feedback).
Comment 5 Fedora Update System 2012-07-27 21:22:20 EDT
python-cherrypy-3.2.2-2.fc16 has been pushed to the Fedora 16 stable repository.  If problems still persist, please make note of it in this bug report.

Note You need to log in before you can comment on or make changes to this bug.