Skip to content

Commit fad89ba

Browse files
authored
feat: add HTTPS (RFC 9460) DNS record type (#1360)
* feat: add HTTPS (RFC 9460) DNS record type Adds 'HTTPS' to the DnsRecordType union so DNS check constructs can monitor a domain's HTTPS service-binding record (HTTP/3 advertisement via alpn, plus ipv4hint/ipv6hint/ech). Updates the DnsAssertionBuilder @example to the recommended assertion forms. * docs: keep the recordType description generic (HTTPS as an @example) * docs: trim the HTTPS assertion example to match the terse pattern
1 parent 4303361 commit fad89ba

2 files changed

Lines changed: 6 additions & 0 deletions

File tree

packages/cli/src/constructs/dns-assertion.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@ export type DnsAssertion = CoreAssertion<DnsAssertionSource>
2121
* // Response code assertions
2222
* DnsAssertionBuilder.responseCode().equals('NOERROR')
2323
* DnsAssertionBuilder.responseCode().equals('NXDOMAIN')
24+
*
25+
* // HTTPS record assertions (HTTP/3 advertisement)
26+
* DnsAssertionBuilder.textAnswer('alpn="([^"]*)"').contains('h3')
27+
* DnsAssertionBuilder.jsonAnswer('$.Answer[0].data').contains('h3')
2428
* ```
2529
*/
2630
export class DnsAssertionBuilder {

packages/cli/src/constructs/dns-request.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ export type DnsRecordType =
88
| 'NS'
99
| 'TXT'
1010
| 'SOA'
11+
| 'HTTPS'
1112

1213
export type DnsProtocol =
1314
| 'UDP'
@@ -24,6 +25,7 @@ export interface DnsRequest {
2425
* @example "A"
2526
* @example "AAAA"
2627
* @example "TXT"
28+
* @example "HTTPS"
2729
*/
2830
recordType: DnsRecordType
2931

0 commit comments

Comments
 (0)