Closed Bug 76975 Opened 23 years ago Closed 22 years ago

[MLK] Leaking C strings in nsNSSComponent::ConfigureInternalPKCS11Token()

Categories

(Core Graveyard :: Security: UI, defect, P3)

1.0 Branch
defect

Tracking

(Not tracked)

VERIFIED WONTFIX
Future

People

(Reporter: beard, Assigned: javi)

References

()

Details

(Keywords: memory-leak)

All the calls to GetPK11String() in this method allocate strings. The call to  
PK11_ConfigurePKCS11() at the bottom of the method evidently copies all of those 
strings, thus all of the allocated strings leak. The URL above points to just one 
of the lines where a leaked string is allocated.
Keywords: mlk
Component: Libraries → Client Library
Product: NSS → PSM
Target Milestone: --- → 2.0
Version: 3.0 → 2.0
This is a one time leak caused by NSS not freeing the strings passed in for
intializing the token names.  A possible work around is to declare our own
global static char arrays and populate and pass it to the PK11 libraries.

This is a one time less than 300 bytes.
->p3
Priority: -- → P3
Mass reassigning target to 2.1
Target Milestone: 2.0 → 2.1
Keywords: nsenterprise
remove nsenterprise.
Keywords: nsenterprise
Moving all P3 and P4 bugs targetted to 2.1 to future.
Target Milestone: 2.1 → Future
Blocks: 92580
No longer blocks: 92580
Changed the QA contact to Bishakha.
QA Contact: sonja.mirtitsch → bishakhabanerjee
This is not a PSM bug.

PSM by itself is not leaking (at least it does no longer leak, if it ever leaked
in the past).

PSM passes internal buffers of automatic strings to PK11_ConfigurePKCS11. It
will free the temporaray strings after the call.

If you think NSS is leaking and should free its strings on shutdown, please
reopen and change this into a NSS bug.
Status: NEW → RESOLVED
Closed: 22 years ago
Resolution: --- → WONTFIX
I think this was fixed in another bug (perhaps even one filed after this one).
Verified.
Status: RESOLVED → VERIFIED
Product: PSM → Core
Version: psm2.0 → 1.0 Branch
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.