zonemaster-engine icon indicating copy to clipboard operation
zonemaster-engine copied to clipboard

Normalize zone name before test start

Open matsduf opened this issue 4 years ago • 3 comments

DNS does not make a distinction between lower case and upper case of ASCII letter, but Zonemaster-Engine preserves case through the machinery.

Change the API and implementation of Zonemaster-Engine so that it always down case the submitted zone name before doing any process.

If the zone name has any IDN A-labels those should also be in lower case.

A discussion is needed for the handling of any IDN U-labels in the zone name.

This is related to issue #734.


Make what has been added by #1040 being used.

matsduf avatar May 20 '20 09:05 matsduf

I completely agree that this should be done. I'm not sure it requires any API changes though. To me it feels more like a refactoring. In case we've forgotten another lc in some test case some bug might get fixed, but module/function signatures and intended behaviors should remain unaffected.

mattias-p avatar May 20 '20 14:05 mattias-p

What I meant by API was that if Engine returns the tested zone name in a formal string, then that might be in a different case. Maybe it is not needed.

matsduf avatar May 20 '20 14:05 matsduf

Partly solved by #1040, only because that Perl module is not used anywhere yet.

tgreenx avatar Jun 14 '23 09:06 tgreenx

Partly solved by #1040, only because that Perl module is not used anywhere yet.

Now used by both interfaces (CLI and Backend) since release v2023.2, see https://github.com/zonemaster/zonemaster-cli/pull/357 and https://github.com/zonemaster/zonemaster-backend/pull/1132.

tgreenx avatar Sep 17 '24 13:09 tgreenx