isPrivateHost
Auto-generated API reference for isPrivateHost.
Function: isPrivateHost()
isPrivateHost(
host):Promise<boolean>
Defined in: safe-fetch.ts:73
Decide whether host resolves to a private/loopback/link-local address.
Host literals are checked exactly; hostnames are resolved via
node:dns/promises when available. Fails closed on any DNS failure (e.g.
edge runtime) so a misconfigured resolver can't open the SSRF gap.
#Parameters
#host
string
#Returns
Promise<boolean>