SSL custom certificates do not work with anything using request in a venv

Bug #1771565 reported by Dmitry Tantsur
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
tripleo
Fix Released
Medium
Dmitry Tantsur

Bug Description

Not a production problem, but hurts development a lot:

$ tox -evenv -- ironic node-list
venv runtests: PYTHONHASHSEED='3657712579'
venv runtests: commands[0] | ironic node-list
The "ironic" CLI is deprecated and will be removed in the S* release. Please use the "openstack baremetal" CLI instead.
Must provide Keystone credentials or user-defined endpoint and token, error was: Could not find versioned identity endpoints when attempting to authenticate. Please check that your auth_url is correct. SSL excep
tion connecting to https://192.168.24.2:13000/: HTTPSConnectionPool(host='192.168.24.2', port=13000): Max retries exceeded with url: / (Caused by SSLError(SSLError("bad handshake: Error([('SSL routines', 'tls_pr
ocess_server_certificate', 'certificate verify failed')],)",),))

This is probably because requests ships its own CA bundle. Setting OS_CACERT to /etc/pki/ca-trust/source/anchors/cm-local-ca.pem or passing it via --os-cacert fixes the problem.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to tripleo-heat-templates (master)

Fix proposed to branch: master
Review: https://review.openstack.org/568853

Changed in tripleo:
status: Triaged → In Progress
Changed in tripleo:
milestone: rocky-2 → rocky-3
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to tripleo-heat-templates (master)

Reviewed: https://review.openstack.org/568853
Committed: https://git.openstack.org/cgit/openstack/tripleo-heat-templates/commit/?id=28be1058f6518450c1106a4ff0488b2159853680
Submitter: Zuul
Branch: master

commit 28be1058f6518450c1106a4ff0488b2159853680
Author: Dmitry Tantsur <email address hidden>
Date: Wed May 16 15:52:46 2018 +0200

    undercloud: set OS_CACERT when TLS is used

    This fixes TLS errors when anything using python-requests is run
    from a virtualenv.

    Change-Id: Icf659e54e8887dc9759cd4d8f732982ce3e0ae5f
    Closes-Bug: #1771565

Changed in tripleo:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/tripleo-heat-templates 9.0.0.0b4

This issue was fixed in the openstack/tripleo-heat-templates 9.0.0.0b4 development milestone.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.