Bug 587559

Summary: nss: incorrect initialization of the server name cache [rhel-6]
Product: Red Hat Enterprise Linux 6 Reporter: Tomas Hoger <thoger>
Component: nssAssignee: Elio Maldonado Batiz <emaldona>
Status: CLOSED CURRENTRELEASE QA Contact: BaseOS QE Security Team <qe-baseos-security>
Severity: medium Docs Contact:
Priority: medium    
Version: 6.0CC: amarecek
Target Milestone: rc   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: 3.12.7-2.el6 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: 571464 Environment:
Last Closed: 2010-09-22 17:53:31 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Tomas Hoger 2010-04-30 09:28:17 UTC
Current NSS in EL6 seems affected by this too, so better fix it before GA.


+++ This bug was initially created as a clone of Bug #571464 +++

Description of problem:
When tstclnt is used with -r 2 option server break the connection.

Version-Release number of selected component (if applicable):
nss-tools-3.12.6-1.el5_4
nss-3.12.6-1.el5_4


How reproducible:
Always.

Steps to Reproduce:
1. Create NSS database and import keys (http://barstool.build.redhat.com/~thoger/CVE-2009-3555/)
2. Run selfserv: selfserv -d /nss/database -n www.example.com -p 4433 -v
3. Run ctstclnt: tstclnt -h www.example.com -p 4433 -d /nss/database -r 2 -2
  
Actual results:
Client:
subject DN: CN=www.example.com,OU=Web Servers,O=My Company Ltd,ST=Berkshire,C=GB
issuer  DN: CN=CA.example.com,OU=Certificate Authority,O=My Company Ltd,L=Newbury,ST=Berkshire,C=GB
0 cache hits; 1 cache misses, 0 cache not reusable
0 stateless resumes
subject DN: CN=www.example.com,OU=Web Servers,O=My Company Ltd,ST=Berkshire,C=GB
issuer  DN: CN=CA.example.com,OU=Certificate Authority,O=My Company Ltd,L=Newbury,ST=Berkshire,C=GB
1 cache hits; 1 cache misses, 0 cache not reusable
0 stateless resumes
tstclnt: read from socket failed: Cannot communicate securely with peer: no common encryption algorithm(s).

Server:
selfserv: About to call accept.
selfserv: HDX PR_Read returned error -12182:
SSL peer has no certificate for the requested DNS name.


[ ... ]


--- Additional comment from thoger on 2010-03-08 13:53:11 EST ---

Looks like server names are not properly inserted into session cache:
  https://bugzilla.mozilla.org/show_bug.cgi?id=360421#c44


[ ... ]


--- Additional comment from thoger on 2010-03-31 10:08:18 EDT ---

Fix for the server name cache initialization issue:

http://bonsai.mozilla.org/cvsview2.cgi?diff_mode=context&whitespace_mode=show&subdir=mozilla/security/nss/lib/ssl&command=DIFF_FRAMESET&file=sslsnce.c&rev1=1.52&rev2=1.53&root=/cvsroot

Comment 1 RHEL Program Management 2010-04-30 09:45:36 UTC
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux major release.  Product Management has requested further
review of this request by Red Hat Engineering, for potential inclusion in a Red
Hat Enterprise Linux Major release.  This request is not yet committed for
inclusion.

Comment 5 RHEL Program Management 2010-07-15 15:10:15 UTC
This issue has been proposed when we are only considering blocker
issues in the current Red Hat Enterprise Linux release. It has
been denied for the current Red Hat Enterprise Linux release.

** If you would still like this issue considered for the current
release, ask your support representative to file as a blocker on
your behalf. Otherwise ask that it be considered for the next
Red Hat Enterprise Linux release. **

Comment 7 Tomas Hoger 2010-09-08 08:47:46 UTC
Upstream patch is included in upstream 3.12.7.  I've checked that the problem can no longer be reproduced with 3.12.7 RHEL-5 packages.  It should be safe to close this now.

Comment 9 Elio Maldonado Batiz 2010-09-22 17:36:28 UTC
With the recent nss rebase to 3.12.7 this fix is already on rhel 6.0.