Bug 653619 - specifying directory or other non-file can crash pemnss
specifying directory or other non-file can crash pemnss
Status: CLOSED DUPLICATE of bug 642433
Product: Fedora
Classification: Fedora
Component: nss (Show other bugs)
14
Unspecified Unspecified
low Severity medium
: ---
: ---
Assigned To: Elio Maldonado Batiz
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2010-11-15 14:56 EST by Rich Megginson
Modified: 2010-11-15 15:33 EST (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-11-15 15:33:53 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Rich Megginson 2010-11-15 14:56:46 EST
Adding a cert or key from a pem file causes a crash:

	PK11_SETATTRS( attrs, CKA_CLASS, &objClass, sizeof(objClass) ); attrs++;
	PK11_SETATTRS( attrs, CKA_TOKEN, &cktrue, sizeof(CK_BBOOL) ); attrs++;
	PK11_SETATTRS( attrs, CKA_LABEL, (unsigned char *)filename, strlen(filename)+1 ); attrs++;
	if ( isca ) {
		PK11_SETATTRS( attrs, CKA_TRUST, &cktrue, sizeof(CK_BBOOL) ); attrs++;
	} else {
		PK11_SETATTRS( attrs, CKA_TRUST, &ckfalse, sizeof(CK_BBOOL) ); attrs++;
	}
	/* This loads the certificate in our PEM module into the appropriate
	 * slot.
	 */
	rv = PK11_CreateGenericObject( slot, theTemplate, 4, PR_FALSE /* isPerm */ );

e.g. if filename is the name of a directory or other non-file (device, socket, etc.), pemnss will crash.
Comment 1 Kamil Dudka 2010-11-15 15:08:35 EST
Is this a duplicate of bug 642433 ?
Comment 2 Rich Megginson 2010-11-15 15:33:53 EST

*** This bug has been marked as a duplicate of bug 642433 ***

Note You need to log in before you can comment on or make changes to this bug.