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

wildcard domain #21

Open
gitmacer opened this issue May 3, 2024 · 6 comments
Open

wildcard domain #21

gitmacer opened this issue May 3, 2024 · 6 comments
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@gitmacer
Copy link

gitmacer commented May 3, 2024

is it possible or can it be added to redirect the wildcard entrie?

.*.mydomain.de. IN TXT forward-domain=https://example.com
is resulting in
"The TXT record data for "
.test.mydomain.de" is missing"

@willnode
Copy link
Owner

willnode commented May 3, 2024

I don't think it will be ever supported since HTTPS verification can be technically difficult. What's your usecase here?

@gitmacer
Copy link
Author

gitmacer commented May 4, 2024

HTTPS verification looks already great to me.
For example:
_.test
TXT
forward-domain=https://example.com/*

With a wildcard Record is already working.

I propose to further reduce the complexity of the DNS setup and maintenance efforts.

If you want to setup an alternative domain you would only need

_.*.gs.short.de
IN TXT
base-domain=gs.short.de; forward-domain=https://greatsite.com

And it should redirect
site1.gs.short.de to site1.greatsite.com
and
123.gs.short.de to 123.greatsite.com

With updating the subdomains on the greatsite.com domain the alternative domains would be working without change.

I propose base-domain to specify if/which subdomain should get attached. None if base-domain not provided.

@willnode
Copy link
Owner

willnode commented May 4, 2024

Just want to make sure, we can set _.*.gs.short.de TXT record and set *.gs.short.de CNAME record already? I never thought we can set wildcard in middle of dot labels. I need to read it somewhere.

@gitmacer
Copy link
Author

gitmacer commented May 4, 2024

I noticed * in middle of dot labels is settable but isn't actually supported.
txtdirect.org is using "_" as wildcard.

An sufficient and simpler solution would be to simply search for the first forward-domain entry in the domain path and attach the
subdomainpath to it.

Wildcard CNAME is supported by most registrars. And wildcard A is definitely no problem. Cludflare for example: https://developers.cloudflare.com/dns/manage-dns-records/reference/wildcard-dns-records/

_.gs.short.de
TXT
forward-domain=https://greatsite.com/
gs.short.de
CNAME
r.forwarddomain.net
*.gs.short.de
CNAME
r.forwarddomain.net

is enough to redirect
gs.short.de to greatsite.com
and
site1.gs.short.de to site1.greatsite.com
and
123.gs.short.de to 123.greatsite.com
and
321.123.gs.short.de to 321.123.greatsite.com
...

@willnode
Copy link
Owner

willnode commented May 4, 2024

OK I understand. Although I'd already say there's a tough challenge. We have to turn this software to also be a DNS resolver so DNS validation for wildcard works (so acme dns challenge works).

This is might be possible but significant development time is needed as I have to implement a DNS resolver too. Also, a robust design of how we can provide the TXT record of this also needed (lesser DNS talks and an approach to recursive domain resolving).

@willnode willnode added enhancement New feature or request help wanted Extra attention is needed labels May 4, 2024
@willnode
Copy link
Owner

willnode commented May 4, 2024

Just for clarification, it's technically possible to stick with current HTTP validation to Let's Encrypt but I would reject the idea. If you set a wildcard record then we must do wildcard ssl too, otherwise we would face other problems like hitting Let's encrypt rate limit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants