зеркало из https://github.com/mozilla/gecko-dev.git
bug 136806, don't authenticate to friendly slots when adding certs
This commit is contained in:
Родитель
31140bf590
Коммит
341d4faa3c
|
@ -340,10 +340,12 @@ AddCert(PK11SlotInfo *slot, CERTCertDBHandle *handle, char *name, char *trusts,
|
|||
if ( emailcert )
|
||||
CERT_SaveSMimeProfile(tempCert, NULL, NULL);
|
||||
#else
|
||||
rv = PK11_Authenticate(slot, PR_TRUE, pwdata);
|
||||
if (rv != SECSuccess) {
|
||||
SECU_PrintError(progName, "could authenticate to token or database");
|
||||
GEN_BREAK(SECFailure);
|
||||
if (!PK11_IsFriendly(slot)) {
|
||||
rv = PK11_Authenticate(slot, PR_TRUE, pwdata);
|
||||
if (rv != SECSuccess) {
|
||||
SECU_PrintError(progName, "could authenticate to token or database");
|
||||
GEN_BREAK(SECFailure);
|
||||
}
|
||||
}
|
||||
|
||||
rv = PK11_ImportCert(slot, cert, CK_INVALID_HANDLE, name, PR_FALSE);
|
||||
|
|
Загрузка…
Ссылка в новой задаче