DescriptionFix a crash in IP address checking because the boundary case for an empty or invalid IP address isn't handled correctly and we can go reading random memory. This doesn't happen during normal host canonicalization because it won't try to canonicalize the IP address of an empty host. It only happens if the app is trying to see if a previously-canonicalized URL is an IP.
BUG=http://code.google.com/p/chromium/issues/detail?id=43819
TEST=none. I wrote a simple unit tests but it doesn't actually work to catch this case. I could not figure out how to get the old code to fail reproducibly, since it starts reading random memory until it finds a character that's invalid. Normally this happens quickly so the crash doesn't occur. It only happens if all characters in memory following the string are valid IP address characters.
Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=134
Patch Set 1 #
Total comments: 1
Messages
Total messages: 3 (0 generated)
|