Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🐛: Zonefile not formatted for subdomains #1137

Open
1 task done
mitchplze opened this issue Jan 30, 2025 · 1 comment
Open
1 task done

🐛: Zonefile not formatted for subdomains #1137

mitchplze opened this issue Jan 30, 2025 · 1 comment
Labels
bug Something isn't working

Comments

@mitchplze
Copy link

What happened?

A bug happened! I think, anyways.

In this case, I think a picture is worth a thousand words.

The DNS record check in the table (first half) shows correctly for a subdomain, but the output zonefile at the bottom, does not generate with the subdomain included in the zonefile.

Instead, all are forced under the naked root domain. I am not super familiar with the DNS zonefile spec, but I believe this is incorrectly being generated in Stalwart, whenever a subdomain exists.

I only discovered this by accident when importing a zonefile to a DNS server without checking it, and it overwrote my production records, with something I was trying to test on a subdomain only. Oops.

Image

How can we reproduce the problem?

I can reproduce the problem by doing the following steps:

Create a subdomain in Management > Directory > Domains
Goto "Check DNS records" screen

Observe zonefile generated at the bottom does not properly include subdomain

Version

v0.11.x

What database are you using?

RocksDB

What blob storage are you using?

RocksDB

Where is your directory located?

Internal

What operating system are you using?

Docker

Relevant log output

Code of Conduct

  • I agree to follow this project's Code of Conduct
@mitchplze mitchplze added the bug Something isn't working label Jan 30, 2025
@mitchplze
Copy link
Author

mitchplze commented Jan 30, 2025

Quick note, when I export a known good zonefile (created in web UI) from Cloudflare DNS, they actually use fqdn with a trailing period. So this would seem to be a valid spec for zonefile and probably a safer implementation overall.

Image

Image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant