summaryrefslogtreecommitdiff
path: root/mach
diff options
context:
space:
mode:
authorRobert Relyea <rrelyea@redhat.com>2022-03-18 15:21:12 -0700
committerRobert Relyea <rrelyea@redhat.com>2022-03-18 15:21:12 -0700
commit1e1791002a5bddb0b5dee8a75889f312b193ff6e (patch)
treec5a1c17469b094c5c94fd3000fb8a7a2d595a898 /mach
parent7d2a566944c72a7347b569de6669c550fe846f6f (diff)
downloadnss-hg-1e1791002a5bddb0b5dee8a75889f312b193ff6e.tar.gz
Bug 1552254 internal_error alert on Certificate Request with sha1+ecdsa in TLS 1.3
We need to be able to select Client certificates based on the schemes sent to us from the server. Rather than changing the callback function, this patch adds those schemes to the ssl socket info as suggested by Dana. In addition, two helpful functions have been added to aid User applications in properly selecting the Certificate: PRBool SSL_CertIsUsable(PRFileDesc *fd, CERTCertificate *cert) - returns true if the given cert matches the schemes of the server, the schemes configured on the socket, capability of the token the private key resides on, and the current policy. For future SSL protocol, additional restrictions may be parsed. SSL_FilterCertListBySocket(PRFileDesc *fd, CERTCertList *certlist) - removes the certs from the cert list that doesn't pass the SSL_CertIsUsable() call. In addition the built in cert selection function (NSS_GetClientAuthData) uses the above functions to filter the list. In order to support the NSS_GetClientAuthData three new functions have been added: SECStatus CERT_FilterCertListByNickname(CERTCertList *certList, char *nickname, void *pwarg) -- removes the certs that don't match the 'nickname'. SECStatus CERT_FilterCertListByCertList(CERTCertlist *certList, const CERTCertlist *filterList ) -- removes all the certs on the first cert list that isn't on the second. PRBool CERT_IsInList(CERTCertificate *, const CERTCertList *certList) -- returns true if cert is on certList. In addition * PK11_FindObjectForCert() is exported so the token the cert lives on can be accessed. * the ssle ssl_PickClientSignatureScheme() function (along with several supporing functions) have been modified so it can be used by SSL_CertIsUsable() Differential Revision: https://phabricator.services.mozilla.com/D135715
Diffstat (limited to 'mach')
-rwxr-xr-xmach3
1 files changed, 2 insertions, 1 deletions
diff --git a/mach b/mach
index a3ef38dac..f34eb5654 100755
--- a/mach
+++ b/mach
@@ -176,7 +176,8 @@ class covAction(argparse.Action):
env = {
"GTESTFILTER": "*", # Prevent parallel test runs.
"ASAN_OPTIONS": "coverage=1:coverage_dir=" + outdir,
- "NSS_DEFAULT_DB_TYPE": "dbm"
+ "NSS_DEFAULT_DB_TYPE": "sql",
+ "NSS_DISABLE_UNLOAD": "1"
}
run_tests("ssl_gtests", env=env, silent=True)