On 05/25/2012 02:52 PM, Antonio Lobato wrote:
> Hey everyone,
>
> I've run into an issue using nss 3.13.1 when attempting to use
> ldapsearch to connect to a TLS openldap server and get the following
> errors:
>
> TLS: certificate [XXXXXXXXXX] is not valid - CA cert is not valid
> TLS: certificate [XXXXXXXXXX] is not valid - error -8172:Peer's
> certificate issuer has been marked as not trusted by the user..
> TLS: error: connect - force handshake failure: errno 21 - moznss error
> -8157
Just looking at the error message, I would normally guess that the trust
chain is no longer trusted. That is you are chaining to a CA that we've
taken out of the trust list (probably because the CA was compromised).
Since this is an ldap server, I think it's only 20% likely (people do
get globally trusted certs for ldap servers, but it's more common they
they use a cert in their own infrastructure.
The next most likely cause would be that one of the certs in your cert
chain matches a compromised certificate in the builtin trust store
(matches by issuer and serial number).
Finally, check your nss database. If you have a intermediate cert with
the 'peer' bit on 'p', that actually marks the intermediate as
untrusted. In NSS 3.12 the 'p==untrusted' only applied to leaf certs, it
was ignored otherwise. In NSS 3.13 it also applies to intermediate
certs. If it's on (and no other trust bits are on), then the certificate
is explictly distrusted. My guess is this is your problem.
bob