chiark / gitweb /
Add some useful-looking TLSA records to hedge against CA uselessness.
[zones] / distorted.lisp
CommitLineData
e80b4c2d
MW
1;;; Zone file for distorted.org.uk
2
b4d4c18b 3(load "hosts.lisp" :verbose nil)
e80b4c2d 4
b1d5c6c2 5;;;--------------------------------------------------------------------------
aef7892b
MW
6;;; Anycast services.
7
8(defvar *anycast-routable-families* (list :ipv6))
9
10(defzoneparse :anycast (name data rec :prefix prefix :zname zname)
11 (destructuring-bind (any-provider default-provider &rest other-providers)
12 data
13
14 ;; First, the default address. If the anycast network is preferred then
15 ;; this is easy; otherwise we have something complicated to do because
16 ;; IPv6 anycast addresses are globally routable, while IPv4 ones aren't.
17 (if (zone-preferred-subnet-p (car any-provider))
18 (zone-set-address #'rec (cdr any-provider) :make-ptr-p t)
6baf2de2 19 (do-host (addr (cdr any-provider))
aef7892b
MW
20 (let ((family (ipaddr-family addr)))
21 (if (member family *anycast-routable-families*)
22 (zone-set-address #'rec addr
23 :family family :make-ptr-p t)
24 (zone-set-address #'rec (cdr default-provider)
25 :family family :make-ptr-p nil)))))
26
27 ;; Now for all of the others.
28 (dolist (provider (list* any-provider default-provider other-providers))
29 (zone-set-address #'rec (cdr provider)
30 :make-ptr-p (eq provider any-provider)
c9f96590
MW
31 :name (domain-name-concat prefix
32 (zone-parse-host
33 (car provider)
34 zname))))))
aef7892b
MW
35
36;;;--------------------------------------------------------------------------
b1d5c6c2 37;;; Other definitions.
e80b4c2d
MW
38
39(setf *default-zone-admin* "hostmaster@distorted.org.uk")
2bc217e8 40
ff6c53ad 41(setf *default-zone-source* 'radius.distorted.org.uk.)
e80b4c2d 42
b1d5c6c2
MW
43;;;--------------------------------------------------------------------------
44;;; Main zone definition.
45
e80b4c2d 46(defzone distorted.org.uk
ec4898f9 47
6ef39f28 48 ;; Nameservers.
ff6c53ad 49 :ns #+view/inside ((radius.ns :ip radius)
f0209b9c 50 (precision.ns :ip precision)
1b9508ad 51 (telecaster.ns :ip telecaster)
ff6c53ad
MW
52 (vampire.ns :ip vampire))
53 #-view/inside ((radius.ns :ip radius)
f0209b9c 54 (precision.ns :ip precision)
1b9508ad 55 (telecaster.ns :ip telecaster)
ff6c53ad 56 (mythic-beasts-1.ns :ip mythic-ns1)
4a487d58 57 (mythic-beasts-2.ns :ip mythic-ns2)
ff6c53ad 58 (chiark.ns :ip chiark.greenend.org.uk))
ec4898f9 59
6ef39f28 60 ;; Mail servers.
cf079d8b 61 ((@ mail blackhole)
96c2a692
MW
62 :mx mail
63 :srv ((:smtp mail)))
39567ec1
MW
64 ((lists bugs cryptomail)
65 :ttl 300
66 :mx mail
67 :srv ((:smtp old-mail)))
ec4898f9 68
69bbb181 69 (stratocaster.20140403._domainkey
8d261a89
MW
70 :dkim ("stratocaster-20140403"
71 :v "DKIM1" :k "rsa" :h "sha256" :s "email"))
69bbb181 72
06f1bb3f 73 ;; Anycast services.
aef7892b
MW
74 (dns0 :anycast ((any dns0.any)
75 (jump precision.jump)
76 (colo precision.colo)
77 (dmz radius.dmz)
78 (unsafe radius.unsafe)))
79 (dns1 :anycast ((any dns1.any)
80 (jump telecaster.jump)
81 (dmz vampire.dmz)
82 (unsafe vampire.unsafe)
83 (colo telecaster.colo)))
cfecfa5c
MW
84 (dns :cname dns0)
85
aef7892b
MW
86 (ntp0 :anycast ((any ntp0.any)
87 (jump fender.jump)
88 (dmz ibanez.dmz)
89 (unsafe ibanez.unsafe)
90 (colo fender.colo)))
91 (ntp1 :anycast ((any ntp1.any)
92 (dmz vampire.dmz)
93 (unsafe vampire.unsafe)))
cfecfa5c
MW
94 (ntp :cname ntp0)
95
aef7892b 96 (www-cache :anycast ((any www-cache.any)
6fcf076f
MW
97 (jump telecaster.jump)
98 (dmz roadstar.dmz)
99 (unsafe roadstar.unsafe)
100 (colo telecaster.colo)))
345c0f69
MW
101 (wpad :cname www-cache)
102
cfecfa5c 103 (_kerberos :txt "DISTORTED.ORG.UK")
aef7892b
MW
104 (krb0 :anycast ((any krb0.any)
105 (jump precision.jump)
106 (dmz radius.dmz)
107 (unsafe radius.unsafe)
108 (colo precision.colo)))
109 (krb1 :anycast ((any krb1.any)
110 (dmz vampire.dmz)
111 (unsafe vampire.unsafe)))
cfecfa5c
MW
112 (krb-master (unsafe :svc radius.unsafe)
113 (dmz :svc radius.dmz))
114 :srv (((:kerberos :protocol :udp)
115 krb0
116 (krb1 :prio 100))
117 ((:kerberos-master :protocol :udp :port 88) krb-master)
118 (:kerberos-adm krb-master)
119 ((:kpasswd :protocol :udp) krb-master))
120 (krb :cname krb0)
121
6ef39f28 122 ;; Other services.
96c2a692
MW
123 :srv ((:http www)
124 (:ftp ftp))
ec4898f9 125
92e99247 126 ;; Entry is via little router box.
ff6c53ad 127 (dmz :net dmz)
c3997955 128 (guvnor (dmz :addr guvnor.dmz))
c3997955 129 (nat (dmz :addr nat.dmz))
ec4898f9 130
6ef39f28 131 ;; Wireless gateway.
ff6c53ad 132 (wireless :net wireless)
c3997955 133 (evolution (safe :addr evolution.safe))
9c43df2a 134 (evolution :alias evo)
ec4898f9 135
4c25329e 136 ;; Colocated services.
8d261a89
MW
137 ((irc vox) (colo :svc jazz.colo :sshfp "jazz")
138 (jump :svc jazz.jump :sshfp "jazz"))
139 ((git www mail) (colo :svc stratocaster.colo :sshfp "stratocaster")
140 (jump :svc stratocaster.jump :sshfp "stratocaster"))
d9fb2838
MW
141 ((www @) :tlsa (:https (:service-certificate-constraint
142 :certificate :sha-256
143 #p"certs/http-server-www#1.cert")))
144 (git :tlsa (:https (:trust-anchor-assertion
145 :certificate :sha-256
146 #p"certs/distorted-ca.cert")))
147 (www-cache :tlsa (3127 (:trust-anchor-assertion
148 :certificate :sha-256
149 #p"certs/distorted-ca.cert")))
150 (mail :tlsa ((:smtp :submission :imap) (:trust-anchor-assertion
151 :certificate :sha-256
152 #p"certs/distorted-ca.cert")))
d13943aa
MW
153 :svc #+view/inside stratocaster.colo
154 #-view/inside stratocaster.jump
8d261a89 155 (cabal :svc stratocaster.colo :sshfp "stratocaster")
0dccfb48
MW
156 ((db ftp) (colo :svc telecaster.colo :sshfp "telecaster")
157 (jump :svc telecaster.jump :sshfp "telecaster"))
158 (dyndns :svc telecaster.jump :sshfp "telecaster")
4c25329e 159
6ef39f28 160 ;; Local services.
6c719992
MW
161 ((rawk pifi) (unsafe :svc artist.unsafe)
162 (dmz :svc artist.dmz))
8d261a89
MW
163 (mirror (dmz :svc roadstar.dmz :sshfp "roadstar")
164 (unsafe :svc roadstar.unsafe :sshfp "roadstar"))
165 ((wiki bugs old-mail i2p) :svc vampire :sshfp "vampire")
ec4898f9 166
6ef39f28 167 ;; Internal services.
8d261a89 168 #+view/inside ((news lpr) :svc vampire.unsafe :sshfp "vampire")
ec4898f9 169
04db9729 170 ;; Anonymity services.
0865ffd5 171 (anon (colo :svc jazz.colo)
f99b371f 172 (unsafe :svc vampire.unsafe)
c3997955
MW
173 (jump :addr anon.jump)
174 (dmz :addr anon.dmz))
04db9729 175
85a3496c 176 ;; Fancy connectivity.
d267cd94 177 (iodine (jump :svc jazz.jump))
85a3496c 178
38c2de7c
MW
179 ;; Colocated hosts.
180 (colo :net colo)
181 (jump :net jump)
9b7e4069 182 (gate (jump :addr gate.jump :sshfp "precision"))
c3997955
MW
183 (fender (colo :addr fender.colo :sshfp "fender")
184 (jump :addr fender.jump :sshfp "fender"))
185 (precision (colo :addr precision.colo :sshfp "precision")
186 (jump :addr precision.jump :sshfp "precision"))
187 (telecaster (colo :addr telecaster.colo :sshfp "telecaster")
188 (jump :addr telecaster.jump :sshfp "telecaster"))
38c2de7c 189 (telecaster :alias tele)
c3997955
MW
190 (stratocaster (colo :addr stratocaster.colo :sshfp "stratocaster")
191 (jump :addr stratocaster.jump :sshfp "stratocaster"))
38c2de7c 192 (stratocaster :alias strat)
c3997955
MW
193 (jazz (colo :addr jazz.colo :sshfp "jazz")
194 (jump :addr jazz.jump :sshfp "jazz")
195 (iodine :addr jazz.iodine :sshfp "jazz"))
38c2de7c 196
4a372d1b 197 ;; Media server (on loan to Good Technology HSTG).
376a10ac 198 (jaguar (jump :addr jaguar.jump :sshfp "jaguar"))
4a372d1b 199
a20ec58c 200 ;; Nicko's server.
c1f47051 201 (richmond (jump :svc richmond.jump))
a20ec58c 202
6ef39f28 203 ;; Wired ethernet.
04d65182
MW
204 (unsafe :net unsafe)
205 (safe :net safe)
206 (untrusted :net untrusted)
c3997955
MW
207 (vampire (unsafe :addr vampire.unsafe :sshfp "vampire")
208 (dmz :addr vampire.dmz :sshfp "vampire")
209 (safe :addr vampire.safe :sshfp "vampire")
210 (untrusted :addr vampire.untrusted :sshfp "vampire"))
211 (ibanez (unsafe :addr ibanez.unsafe :sshfp "ibanez")
212 (dmz :addr ibanez.dmz :sshfp "ibanez"))
213 (radius (unsafe :addr radius.unsafe :sshfp "radius")
214 (dmz :addr radius.dmz :sshfp "radius")
215 (safe :addr radius.safe :sshfp "radius")
216 (untrusted :addr radius.untrusted :sshfp "radius"))
217 (roadstar (unsafe :addr roadstar.unsafe :sshfp "roadstar")
218 (dmz :addr roadstar.dmz :sshfp "roadstar"))
219 (jem (unsafe :addr jem.unsafe :sshfp "jem")
220 (dmz :addr jem.dmz :sshfp "jem"))
221 (artist (unsafe :addr artist.unsafe :sshfp "artist")
222 (dmz :addr artist.dmz :sshfp "artist")
223 (untrusted :addr artist.untrusted :sshfp "artist"))
ec4898f9 224
ff6c53ad 225 ;; DHCP hosts.
4b5e05ad
MW
226 (gibson :cname gibson.dhcp)
227 (lespaul :cname lespaul.dhcp)
228 (firebird :cname firebird.dhcp)
aa4d55b1
MW
229 (marauder :cname marauder.dhcp)
230 (invader :cname invader.dhcp)
ec4898f9 231
6ef39f28 232 ;; Virtual network.
374be896 233 (vpn :net vpn)
c3997955
MW
234 (crybaby (vpn :addr crybaby.vpn :sshfp "crybaby"))
235 (terror (vpn :addr terror.vpn :sshfp "terror"))
236 (orange (vpn :addr orange.vpn :sshfp "orange"))
76bca42f 237 (haze (vpn :addr haze.vpn :sshfp "haze"))
fc0ce2ed 238 (iodine :net iodine)
ec4898f9 239
6ef39f28 240 ;; ITS.
b1d5c6c2 241 (its :net its)
c3997955
MW
242 (gw (its :addr gw.its))
243 (mz (its :addr mz.its))
ec4898f9 244
c2118713 245 ;; Strange things.
c3997955 246 (blackhole (jump :addr blackhole.jump))
c2118713 247
6ef39f28 248 ;; Delegations.
f0209b9c
MW
249 (dhcp :ns ((radius.ns.dhcp :ip radius)
250 (precision.ns.dhcp :ip precision)
1b9508ad 251 (telecaster.ns.dhcp :ip telecaster)
f0209b9c 252 (vampire.ns.dhcp :ip vampire)))
49c5f8ff
MW
253 (dyn :ns ((radius.ns.dyn :ip radius)
254 (precision.ns.dyn :ip precision)
1b9508ad 255 (telecaster.ns.dyn :ip telecaster)
49c5f8ff 256 (vampire.ns.dyn :ip vampire)))
0262908f 257 (dnserr :ns ((radius.ns.dnserr :ip radius.dmz)
f0209b9c 258 (precision.ns.dnserr :ip precision.jump)
1b9508ad 259 (telecaster.ns.dnserr :ip telecaster)
0262908f 260 (vampire.ns.dnserr :ip vampire.dmz)))
17c95de9 261 (io :ns ((ns.io :ip jazz.jump))))
b1d5c6c2
MW
262
263;;;--------------------------------------------------------------------------
264;;; Other subsidiary zones.
e80b4c2d 265
55f161b6
MW
266(defzone dhcp.distorted.org.uk
267 (gibson :addr gibson.unsafe)
268 (lespaul :addr lespaul.safe)
269 (invader :addr invader.safe)
270 (marauder :addr marauder.safe))
271
c1f47051
MW
272(defzone nicko.org
273 (richmond :addr richmond.jump))
274
e80b4c2d 275(defrevzone trusted
8aa87005
MW
276 :ns (radius.distorted.org.uk.
277 precision.distorted.org.uk.
1b9508ad 278 telecaster.distorted.org.uk.
8aa87005 279 vampire.distorted.org.uk.)
b59ce50d
MW
280 :reverse unsafe
281 :reverse vpn
282 :reverse colo
283 :reverse its
345c0f69 284 :reverse any
8aa87005
MW
285 (dhcp :ns (radius.distorted.org.uk.
286 precision.distorted.org.uk.
1b9508ad 287 telecaster.distorted.org.uk.
8aa87005 288 vampire.distorted.org.uk.))
3503589d 289 :multi (((dhcp safe) :family :ipv4 :suffix "199.29.172.dhcp") :cname *))
b3f75214 290
b29264c5 291(defrevzone (dmz :family :ipv6)
8aa87005
MW
292 :ns (radius.distorted.org.uk.
293 precision.distorted.org.uk.
1b9508ad 294 telecaster.distorted.org.uk.
8aa87005 295 vampire.distorted.org.uk.)
ff6c53ad 296 :reverse dmz)
92e99247 297
b29264c5
MW
298(defrevzone (dmz :family :ipv4)
299 (144-159 :ns (radius.distorted.org.uk.
300 precision.distorted.org.uk.
301 telecaster.distorted.org.uk.
302 vampire.distorted.org.uk.))
303 :multi ((dmz :suffix "144-159") :cname *))
304
305(defzone 144-159.204.49.62.in-addr.arpa
306 :ns (radius.distorted.org.uk.
307 precision.distorted.org.uk.
308 telecaster.distorted.org.uk.
309 vampire.distorted.org.uk.)
310 :reverse ((((:ipv4 dmz)))))
311
312(defrevzone (jump :family :ipv6)
8aa87005
MW
313 :ns (radius.distorted.org.uk.
314 precision.distorted.org.uk.
1b9508ad 315 telecaster.distorted.org.uk.
8aa87005 316 vampire.distorted.org.uk.)
38c2de7c
MW
317 :reverse jump)
318
b29264c5
MW
319(defrevzone (jump :family :ipv4)
320 (64-79 :ns (radius.distorted.org.uk.
321 precision.distorted.org.uk.
322 telecaster.distorted.org.uk.
323 vampire.distorted.org.uk.))
324 :multi ((jump :suffix "64-79") :cname *))
325
326(defzone 64-79.198.13.212.in-addr.arpa
327 :ns (radius.distorted.org.uk.
328 precision.distorted.org.uk.
329 telecaster.distorted.org.uk.
330 vampire.distorted.org.uk.)
331 :reverse ((((:ipv4 jump)))))
332
652c34be
MW
333(defrevzone distorted.org.uk-he
334 :ns (radius.distorted.org.uk.
335 precision.distorted.org.uk.
1b9508ad 336 telecaster.distorted.org.uk.
652c34be
MW
337 vampire.distorted.org.uk.)
338 :reverse distorted.org.uk-he)
339
340(defrevzone distorted.org.uk-jump
341 :ns (radius.distorted.org.uk.
342 precision.distorted.org.uk.
1b9508ad 343 telecaster.distorted.org.uk.
652c34be
MW
344 vampire.distorted.org.uk.)
345 :reverse distorted.org.uk-jump)
346
995d75b4 347(defzone io.distorted.org.uk
17c95de9 348 :ns ((ns :ip jazz.jump))
995d75b4
MW
349 (about :txt "Fake zone used for IP-over-DNS tunnelling."))
350
b1d5c6c2 351;;;----- That's all, folks --------------------------------------------------