Skip to content

Instantly share code, notes, and snippets.

@hyjk2000
Last active November 21, 2024 12:24
Show Gist options
  • Save hyjk2000/0ea291bf46e0bf38bb61041885adf9d3 to your computer and use it in GitHub Desktop.
Save hyjk2000/0ea291bf46e0bf38bb61041885adf9d3 to your computer and use it in GitHub Desktop.
Unbound Stub Zones to Prevent Resolving CDN Domains with Google DNS
# Resolving internal domains
local-zone: "local." static
local-data: "example.local. IN A [Internal Server IP]"
# Stub out CDN domains to use local DNS provided by your ISP
stub-zone:
name: "akadns.net"
stub-addr: [Local DNS IP]
stub-zone:
name: "ourdvs.com"
stub-addr: [Local DNS IP]
stub-zone:
name: "ccgslb.com.cn"
stub-addr: [Local DNS IP]
stub-zone:
name: "ourwebcdn.com"
stub-addr: [Local DNS IP]
stub-zone:
name: "aaplimg.com"
stub-addr: [Local DNS IP]
stub-zone:
name: "alicdn.com"
stub-addr: [Local DNS IP]
stub-zone:
name: "ctmcdn.net"
stub-addr: [Local DNS IP]
stub-zone:
name: "l.google.com"
stub-addr: [Local DNS IP]
stub-zone:
name: "fonts.googleapis.com"
stub-addr: [Local DNS IP]
stub-zone:
name: "gstatic.com"
stub-addr: [Local DNS IP]
stub-zone:
name: "google.cn"
stub-addr: [Local DNS IP]
stub-zone:
name: "icloud.com"
stub-addr: [Local DNS IP]
stub-zone:
name: "icloud-content.com"
stub-addr: [Local DNS IP]
stub-zone:
name: "herokuapp.com"
stub-addr: [Local DNS IP]
# Forward all other domains to Google DNS
forward-zone:
name: "."
forward-addr: 8.8.8.8
forward-addr: 8.8.4.4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment