Bug 62145 - Fix crashes when apr_sockaddr_info_get fails
Summary: Fix crashes when apr_sockaddr_info_get fails
Status: NEW
Alias: None
Product: Apache httpd-2
Classification: Unclassified
Component: All (show other bugs)
Version: 2.5-HEAD
Hardware: All All
: P2 normal (vote)
Target Milestone: ---
Assignee: Apache HTTPD Bugs Mailing List
Depends on:
Reported: 2018-03-01 05:42 UTC by Zhouyang
Modified: 2018-09-08 08:14 UTC (History)
0 users

add error handling code for apr_sockaddr_info_get (3.35 KB, patch)
2018-03-01 05:42 UTC, Zhouyang
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Zhouyang 2018-03-01 05:42:56 UTC
Created attachment 35747 [details]
add error handling code for apr_sockaddr_info_get


I'm a PhD student. I analyzed the httpd source code and found apr_sockaddr_info_get missing error handling in several places, which may cause bad results like crash.

Attached please find the patch against master branch. Hopefully, it can solve these potential bugs.

Comment 1 Christophe JAILLET 2018-05-28 20:27:57 UTC

First, thanks a lot for the report.

However, I think that the patch is at least incomplete.
In most cases, you only add some log information, which is useful by itself.
It is likely that a more complete error handling should be performed.

I will try to have a look at it in the coming days, but feel free to double check your proposal and provide a v2 if needed.

Anyway, thanks for your interest in the project proposal to improve it.
Comment 2 Rainer Jung 2018-09-08 08:14:32 UTC
Undo changes done by spammer.