This feature request came to my mind as our company registered a few IDN domains. I'd like to add that IDN domains are a thing now, and should be supported in Aegir so I thought why not.

I created a simple script to convert between Unicode and Ascii with the "Add a site" feature, I'd love to see this in the core but I couldn't get hosting.inc to match the domains :\ I guess the problem is with the domains containing multiple dash's? So as in RFC the domains would be served in the databases and config files in their respected ascii equivalent.

ääkköset.fi <-> xn--kkset-fraa0m.fi

Please see the attached patch proposal for hosting_site.form.js to target converting of the domain names with change of the input fields focus.

Kind regards Ilari Lind

Members fund testing for the Drupal project. Drupal Association Learn more


omega8cc’s picture

Title: IDN domain support for Aegir » IDN domain names on-the-fly conversion
Status: Active » Needs review

Note that stock Aegir supports xn-- format without issues. If you are experiencing problems with it, you are most probably using BOA and there was a bug I just fixed: http://drupalcode.org/sandbox/omega8cc/1074912.git/commit/27bc110

Thanks for the heads up!

As for the inclusion of the on-the-fly converter, I will leave this for other core devs to decide and I'm changing the title to match the real request here, as the bug was elsewhere.

Aciid’s picture

Yeah we use BOA servers thanks for clarifying that the bug was not in Aegir. (Actually I should have had checked that myself by comparing vanilla installation before coming here).


anarcat’s picture

Status: Needs review » Needs work

Sorry, but we need an non-obfuscated version of this code before we even consider reviewing it.

omega8cc’s picture

Anonymous’s picture

Just wanted to add (perhaps this is obvious) that BOA 2.0.5 (current stable version - before applying omega8.cc's fix) also prevents IDN's from displaying the www. version of the IDN BOA-hosted site. Aegir can't save the alias. Thanks for the fix - I just wanted to make sure the fix also addresses this issue, which I believe is the same.

omega8cc’s picture

anarcat’s picture

This looks like a rather big blob of Javascript code to be included here only for a rather exceptionnal (at least now) use case (having *on the fly* conversion). I think we would be better served by regular form processing here - we could send the IDN form to the backend and keep the frontend readable, couldn't we?

And anyways, we do need to have a patch that would include that .js code somewhere... If we are to embed alien JS code in Aegir, we should be careful about licenses, attributions and so on. We also should include it as a separate file.

But I personnally believe this to be overkill. If there are no other solutions proposed, however, who am I to refuse! :)

Aciid’s picture

Hi, I just picked this email again from my inbox.
Surely this is not even a priority and as a feature can be stashed because as a functionality it's so trivial. Only reason why I made it was because I thought it could be fun to code.

In fact the my co-workers asked me in in the scope of the subject "How do I even add IDN-domains to Aegir or our DNS?"

Thats when I explained how I haven't seen this kind of functionality anywhere else. It's serves more as a trifling way to pronounce domains in native language. And the browser converts them to ascii, the IDN version is still visible to user, all communications is being spoken via ascii version of the domain.

Conclusion: "So I have to google 'IDN convert' everytime I wan't to add IDN domains to our Aegir or DNS?" Yeah.

But hey, ths thread has given me quite a insight of how to think my commit's further and maybe try and sharpen them up a bit before trying to release.

As for the licensing of punycode.js part "Punycode.js is dual licensed under the MIT and GPL licenses." Authored by: http://mathiasbynens.be/
Source fork can be found still from github: https://github.com/bestiejs/punycode.js/

TR’s picture

Issue summary: View changes
Issue tags: +IDN

Added IDN tag.

ergonlogic’s picture

Version: 6.x-2.x-dev » 7.x-3.x-dev

New features need to be implemented in Aegir 3.x, then we can consider back-porting to Aegir 2.x.

Yuri’s picture

Currently this is a priority. IDN domains are all over the place on the internet.

Yuri’s picture

omega8cc’s picture

1.11 MB

We have implemented this in BOA. Patch will be submitted soon.


omega8cc’s picture

Status: Needs work » Needs review
1.28 KB

Patch for hostmaster attached (separate patch for hosting in the hosting queue)

helmo’s picture

Status: Needs review » Needs work

depends on #2712227: IDN domain names on-the-fly conversion which needs work ...