Commit 4d06340
committed
fix(dstack-ingress): keep delegation's CAA gate fail-closed
Routing the delegation checks through dnsguide silently changed what the
CAA check means. dnsguide asks "does anything forbid us from issuing",
and under RFC 8659 an absent CAA record set forbids nothing, so it
passes. Delegation asks the opposite question: that record is the only
thing stopping anyone else who can satisfy the delegated challenge from
getting a certificate for the name, and we hold no token to create it, so
its absence is exactly the state that has to block.
The end-to-end run caught it -- with no CAA at all the check reported
"ok (no CAA record set; issuance is unrestricted)" and let issuance
proceed, where #104 would have refused to start. The unit tests did not,
because they only ever asserted on records that exist.
`--caa-required` inverts the rule for this one caller. ALLOW_MISSING_CAA
still downgrades it to a warning, so the escape hatch behaves as
documented.
It is now better than the original in one respect: under DNS_SETUP_MODE
wait the container waits for the operator to create the record rather
than failing on the first look, and still fails after DNS_SETUP_TIMEOUT.
TESTING.md documents how to exercise delegation without a second
registrar account -- any name under a zone you already control works,
because the provider resolves zones by longest-suffix match -- along with
what that substitution does not cover.1 parent 8dad8eb commit 4d06340
4 files changed
Lines changed: 126 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
199 | 199 | | |
200 | 200 | | |
201 | 201 | | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
202 | 247 | | |
203 | 248 | | |
204 | 249 | | |
205 | 250 | | |
206 | 251 | | |
207 | 252 | | |
208 | 253 | | |
| 254 | + | |
209 | 255 | | |
210 | 256 | | |
211 | 257 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
138 | 138 | | |
139 | 139 | | |
140 | 140 | | |
141 | | - | |
| 141 | + | |
142 | 142 | | |
143 | 143 | | |
144 | 144 | | |
145 | 145 | | |
146 | 146 | | |
147 | | - | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
148 | 153 | | |
149 | 154 | | |
150 | 155 | | |
151 | 156 | | |
152 | | - | |
| 157 | + | |
153 | 158 | | |
154 | 159 | | |
155 | 160 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
269 | 269 | | |
270 | 270 | | |
271 | 271 | | |
272 | | - | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
273 | 278 | | |
274 | 279 | | |
275 | 280 | | |
276 | 281 | | |
277 | | - | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
278 | 290 | | |
279 | 291 | | |
280 | 292 | | |
| |||
308 | 320 | | |
309 | 321 | | |
310 | 322 | | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
311 | 328 | | |
312 | 329 | | |
313 | 330 | | |
| |||
341 | 358 | | |
342 | 359 | | |
343 | 360 | | |
| 361 | + | |
344 | 362 | | |
345 | 363 | | |
346 | 364 | | |
| |||
353 | 371 | | |
354 | 372 | | |
355 | 373 | | |
356 | | - | |
| 374 | + | |
| 375 | + | |
| 376 | + | |
357 | 377 | | |
358 | 378 | | |
359 | 379 | | |
| |||
428 | 448 | | |
429 | 449 | | |
430 | 450 | | |
| 451 | + | |
| 452 | + | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
431 | 457 | | |
432 | 458 | | |
433 | 459 | | |
| |||
484 | 510 | | |
485 | 511 | | |
486 | 512 | | |
| 513 | + | |
487 | 514 | | |
488 | 515 | | |
489 | 516 | | |
| |||
Lines changed: 42 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
176 | 176 | | |
177 | 177 | | |
178 | 178 | | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
179 | 221 | | |
180 | 222 | | |
181 | 223 | | |
| |||
0 commit comments