Skip to content

Commit

Permalink
MDL-48779 MNet: multibyte substr in certificate generation
Browse files Browse the repository at this point in the history
Using core_text::substr instead of substr for trimming certificate
data. Is needed for sites with long unicode sitename to prevent
breaking line between unicode pair.
  • Loading branch information
vadimonus committed Jan 16, 2015
1 parent eb1dc9f commit 28d20df
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mnet/lib.php
Expand Up @@ -394,7 +394,7 @@ function mnet_generate_keypair($dn = null, $days=28) {
);

foreach ($dnlimits as $key => $length) {
$dn[$key] = substr($dn[$key], 0, $length);
$dn[$key] = core_text::substr($dn[$key], 0, $length);
}

// ensure we remove trailing slashes
Expand Down

0 comments on commit 28d20df

Please sign in to comment.