mirror of
https://github.com/cunnie/sslip.io.git
synced 2025-10-06 16:18:00 +08:00
PTR: 1.0.0.127.in-addr.arpa → 127.0.0.1.sslip.io
We implement PTR records for IPv4. When a PTR record is not found (e.g. "127.in-addr.arpa"), it returns the SOA record, but, unlike other record lookups (e.g. "MX"), the SOA's mname is locked to "sslip.io" because setting the mname to "127.in-addr.arpa" doesn't make sense. To be done: - Implement IPv6 - Implement Metrics - Update README - Deploy new version
This commit is contained in:
@@ -173,6 +173,22 @@ var _ = Describe("sslip.io-dns-server", func() {
|
||||
"@127.0.0.1 get._acme-challenge.a.b.c.subdomain-key.k-v.io txt +short",
|
||||
`baffled-boy._acme-challenge`,
|
||||
`TypeTXT get._acme-challenge.a.b.c.subdomain-key.k-v.io. \? \["baffled-boy._acme-challenge"\]`),
|
||||
Entry(`get a PTR for 1.0.168.192.in-addr.arpa returns 192.168.0.1.sslip.io`,
|
||||
"@127.0.0.1 1.0.168.192.in-addr.arpa ptr +short",
|
||||
`\A192.168.0.1.sslip.io.\n\z`,
|
||||
`TypePTR 1.0.168.192.in-addr.arpa. \? 192.168.0.1.sslip.io.`),
|
||||
Entry(`get a PTR for 1.0.0.127.blah.in-addr.arpa returns no records`,
|
||||
"@127.0.0.1 1.0.0.127.blah.in-addr.arpa ptr +short",
|
||||
`\A\z`,
|
||||
`TypePTR 1.0.0.127.blah.in-addr.arpa. \? nil, SOA sslip.io. briancunnie.gmail.com. 2022042500 900 900 1800 180\n$`),
|
||||
Entry(`get a PTR for blah.1.0.0.127.in-addr.arpa returns no records`,
|
||||
"@127.0.0.1 blah.1.0.0.127.in-addr.arpa ptr +short",
|
||||
`\A\z`,
|
||||
`TypePTR blah.1.0.0.127.in-addr.arpa. \? nil, SOA sslip.io. briancunnie.gmail.com. 2022042500 900 900 1800 180\n$`),
|
||||
Entry(`get a PTR for 0.0.127.in-addr.arpa returns no records`,
|
||||
"@127.0.0.1 0.0.127.in-addr.arpa ptr +short",
|
||||
`\A\z`,
|
||||
`TypePTR 0.0.127.in-addr.arpa. \? nil, SOA sslip.io. briancunnie.gmail.com. 2022042500 900 900 1800 180\n$`),
|
||||
)
|
||||
})
|
||||
Describe("for more complex assertions", func() {
|
||||
|
Reference in New Issue
Block a user