DNS Problem after creating a DNS entry with unproper name

Hi,

Recently I created, by mistake, a custom DNS entry (“A” Register) including an space in the name “10 whatevername” (for instance). Now I’m not able to remove it, nor to add new entries to this domain (the GUI gime me some times error 500, other times it says OK, yet nslookup to that entry, fails.

Since GUI prevent me deleting the unproper named DNS entry (I saw it on the GUI, but if I press “Delete” I get an “Invalid name.” message). Could I manually remove that entry from the system using the shell (SSH)? I can modify the .txt zone file, but I’m not sure how to sign it (which keys to use and so on). Could you help me on how to fix this issue?

Thanks a lot,
Jesús.

I’ve tried setting an A record through the admin menu and cannot reproduce this. I tried setting the Name field to 10 test but it told me “Invalid Name”. I then tried setting a normal Name but setting the Value field to 10 test and it told me something along the lines of “doesn’t look like a valid IP address”. How exactly did you create an entry with a space in it?

I did with the GUI for sure (indeed, as mentioned, I’m not sure how to manually remove or add things and sign it properly after). The thing is that I just wanted to create a test MX and I put the 10 in front by mistake so I’m not sure what I exactly typed in…

Finally I did a workaround and it seems it worked fine.

It was as follows, I modified dns_update.py, commenting out the next two lines:

771 if not re.search(DOMAIN_RE, qname):
772 raise ValueError(“Invalid name.”)

Restarted mailinabox service, and try to delete the “odd” domain and it worked. After that I uncommented those two lines on dns_update.py and reload mailinabox service.

I tested adding and removing new custom DNS entries and it worked fine. Yet, if there is any reference on how to manually (not using the GUI) update touching the .txt file and signing it and so on could be nice to know.

Best Regards.

3 Likes

I think that perhaps that “odd” DNS entry was added with a previous version that didn’t have the same condition and so is why I was able to create them but not remove them, yet not sure about that.

Wanted to login here just to give you my thanks! I had a record with an invalid name creating havoc with issuance of letsencrypt wildcard certs and this was the solution - thank you!