Affects Version/s: 3.3.2
Fixed Branches:MOODLE_32_STABLE, MOODLE_33_STABLE
Pull from Repository:
Pull Master Branch:wip-
Pull Master Diff URL:
Find curlsecurityblockedhosts in the site administration and try to set it to different values including non-latin domain names such as
Make sure the settings saves and displays back the same value.
Discovered while working on
PHP 7.2 deprecated INTL_IDNA_VARIANT_2003 that we use in admin setting admin_setting_configmixedhostiplist :
cameron1729 and I started looking at the current implementation and Cam noticed that it should be
because otherwise domains like faß.de would not be converted properly.
While testing we found out that regex in line https://github.com/moodle/moodle/blob/master/lib/tests/admintree_test.php#L154 is incorrect and faß.de does not even pass validation
So there are several problems here:
1. correct regex in ace_encode() so it works with mixed ascii and non-ascii characters
2. change arguments for idn_to_ascii and idn_to_unt8
3. add unittests