Bug 1881999
Summary: | 8025 error code when creating subCAs | |||
---|---|---|---|---|
Product: | Red Hat Enterprise Linux 8 | Reporter: | François Cami <fcami> | |
Component: | nss | Assignee: | nss-nspr-maint <nss-nspr-maint> | |
Status: | CLOSED CURRENTRELEASE | QA Contact: | Ivan Nikolchev <inikolch> | |
Severity: | unspecified | Docs Contact: | ||
Priority: | low | |||
Version: | 8.3 | CC: | cheimes, inikolch, rrelyea, ssidhaye, ssorce | |
Target Milestone: | rc | Keywords: | OtherQA, Triaged, ZStream | |
Target Release: | 8.0 | |||
Hardware: | Unspecified | |||
OS: | Unspecified | |||
Whiteboard: | ||||
Fixed In Version: | nss-3.67.0-4.el8 | Doc Type: | No Doc Update | |
Doc Text: | Story Points: | --- | ||
Clone Of: | ||||
: | 1977412 1985061 (view as bug list) | Environment: | ||
Last Closed: | 2021-12-16 11:54:57 UTC | Type: | Bug | |
Regression: | --- | Mount Type: | --- | |
Documentation: | --- | CRM: | ||
Verified Versions: | Category: | --- | ||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | ||
Cloudforms Team: | --- | Target Upstream Version: | ||
Embargoed: | ||||
Bug Depends On: | ||||
Bug Blocks: | 1977412, 1985061 |
Comment 2
Alex Scheel
2020-09-23 16:28:21 UTC
For context, the relevant JSS function (generateRSAKeyPairWithOpFlags) is fairly trivial: JNIEXPORT jobject JNICALL Java_org_mozilla_jss_pkcs11_PK11KeyPairGenerator_generateRSAKeyPairWithOpFlags (JNIEnv *env, jobject this, jobject token, jint keySize, jlong publicExponent, jboolean temporary, jint sensitive, jint extractable, jint op_flags, jint op_flags_mask) { PK11RSAGenParams params; PR_ASSERT(env!=NULL && this!=NULL && token!=NULL); /************************************************** * setup parameters *************************************************/ params.keySizeInBits = keySize; params.pe = publicExponent; return PK11KeyPairGeneratorWithOpFlags(env, this, token, CKM_RSA_PKCS_KEY_PAIR_GEN, ¶ms, temporary, sensitive, extractable, op_flags, op_flags_mask); } At the time it is called (and this executes), we've initialized NSS a while ago (because we've successfully generated keys $count times earlier). So the race condition must happen in the PK11 code somewhere. The question is why is this failure in NSS... now :-) Sorry, PK11KeyPairGeneratorWithOpFlags is actually a JSS function. It calls JSS's JSS_PK11_generateKeyPairWithOpFlags and keysToKeyPair. So, we call the following two PK11 functions: - PK11_Authenticate (should be a no-op if token is already logged in, which it is since we authed earlier). - PK11_GenerateKeyPairWithOpFlags No JSS method returns SEC_ERROR_PKCS11_GENERAL_ERROR, so it is one of these two functions (or the interaction thereof). Guess the next step is a C reproducer without JSS. |