Bug 871034 - if CN matches hostname/IP but does not match explicitly set host subject, the connection should fail
Summary: if CN matches hostname/IP but does not match explicitly set host subject, the...
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: spice-gtk
Version: 6.4
Hardware: Unspecified
OS: Unspecified
Target Milestone: rc
: ---
Assignee: Christophe Fergeau
QA Contact: Desktop QE
Depends On:
Blocks: 873318
TreeView+ depends on / blocked
Reported: 2012-10-29 13:13 UTC by David Jaša
Modified: 2014-10-14 06:46 UTC (History)
8 users (show)

Cause: For SSL connections, we considered the connection to be successful if the certificate subject matched the hostname even if a user-specified host certificate subject was given that didn't match.

Consequence: Remote-viewer connected to the remote host even if the user-specified certificate subject did not match.

Fix: Make the user-specified certificate subject check have priority over the hostname check.

Result: Connections fail if user-specified cert subject doesn't match.
Clone Of:
: 873318 (view as bug list)
Last Closed: 2014-10-14 06:46:25 UTC

Attachments (Terms of Use)

External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2014:1487 normal SHIPPED_LIVE spice-gtk bug fix and enhancement update 2014-10-14 01:28:31 UTC

Description David Jaša 2012-10-29 13:13:30 UTC
Description of problem:
if CN matches hostname/IP but not explicitly set host subject, the connection should fail.

The reason is that externally-provided host subject is likely to be more trustworthy than just check for host/ip == CN equivalence. OpenVPN behaves the suggested way for instance.

Version-Release number of selected component (if applicable):
windows builds affected too

How reproducible:

Steps to Reproduce:
1. have a server with 'CN=server.example.org' in its subject
2. connect to a server:
remote-viewer --spice-ca-file=file --spice-host-subject='CN=something-else' spice://server.example.org/?tls-port=sport
Actual results:
r-v connects

Expected results:
r-v should print host-subject mismatch error and exit

Additional info:

Comment 1 Christophe Fergeau 2013-09-20 15:10:54 UTC
I've sent a potential patch for this to http://lists.freedesktop.org/archives/spice-devel/2013-September/014612.html .

Comment 5 errata-xmlrpc 2014-10-14 06:46:25 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


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