Bug 1111

Summary: memory leak in openbsd-compat/getrrsetbyname.c, function: getrrsetbyname
Product: Portable OpenSSH Reporter: Ted Kremenek <kremenek>
Component: sshAssignee: Damien Miller <djm>
Status: CLOSED FIXED    
Severity: normal    
Priority: P2    
Version: 4.2p1   
Hardware: Other   
OS: All   
Bug Depends on:    
Bug Blocks: 1047    
Attachments:
Description Flags
sync getrrsetbyname.c none

Description Ted Kremenek 2005-11-04 18:02:52 AEDT
In the function getrrsetbyname...

memory allocated by the call to parse_dns_response (which calls calloc):

        /* parse result */
        response = parse_dns_response(answer, length);

... appears to be leaked on all paths in this function.
Comment 1 Damien Miller 2005-11-05 15:46:53 AEDT
Created attachment 1023 [details]
sync getrrsetbyname.c

This can be resolved by syncing our compat code to OpenBSD's latest version of getrrsetbyname(), which already includes fixes for these leaks.
Comment 2 Damien Miller 2005-11-05 16:57:22 AEDT
sync applied and will be in 4.3p1, thanks for the report.
Comment 3 Darren Tucker 2006-10-07 11:43:05 AEST
Change all RESOLVED bug to CLOSED with the exception of the ones fixed post-4.4.