MCPcopy Index your code
hub / github.com/nodejs/node / isIpv6Hostname

Function isIpv6Hostname

lib/url.js:153–159  ·  view source on GitHub ↗
(hostname)

Source from the content-addressed store, hash-verified

151}
152
153function isIpv6Hostname(hostname) {
154 return (
155 StringPrototypeCharCodeAt(hostname, 0) === CHAR_LEFT_SQUARE_BRACKET &&
156 StringPrototypeCharCodeAt(hostname, hostname.length - 1) ===
157 CHAR_RIGHT_SQUARE_BRACKET
158 );
159}
160
161// This prevents some common spoofing bugs due to our use of IDNA toASCII. For
162// compatibility, the set of characters we use here is the *intersection* of

Callers 1

url.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…