[Webkit-unassigned] [Bug 182427] Add a way to check if a host is an IP address

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Feb 2 08:55:55 PST 2018


https://bugs.webkit.org/show_bug.cgi?id=182427

Michael Catanzaro <mcatanzaro at igalia.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |mcatanzaro at igalia.com

--- Comment #8 from Michael Catanzaro <mcatanzaro at igalia.com> ---
Comment on attachment 332963
  --> https://bugs.webkit.org/attachment.cgi?id=332963
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=332963&action=review

Looks good, but I'll hold off on r+ because I bet Alex will want to review this.

> Source/WebCore/page/OriginAccessEntry.cpp:43
> +    , m_hostIsIPAddress(URL::hostIsIPAddress(m_host))

Might be better to drop this member variable in favor of direct calls to hostIsIPAddress(m_host)?

> Source/WebCore/page/OriginAccessEntry.cpp:70
> -    if (m_hostIsIPAddress && m_ipAddressSettings == TreatIPAddressAsIPAddress)
> +    if (m_ipAddressSettings == TreatIPAddressAsIPAddress && (m_hostIsIPAddress || URL::hostIsIPAddress(origin.host())))

I think this is right, but it's an unrelated functionality change. Previously there was no test to check if origin was an IP address, and now there is.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20180202/ca93a273/attachment.html>


More information about the webkit-unassigned mailing list