mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-07-10 06:58:27 +03:00
Fix idn decoding (#1175)
This commit is contained in:
parent
e5af98b04b
commit
1e287f486d
1 changed files with 2 additions and 1 deletions
|
|
@ -2428,6 +2428,7 @@ END;
|
|||
{
|
||||
include_once MAILSO_LIBRARY_ROOT_PATH.'Vendors/Net/IDNA2.php';
|
||||
$oIdn = new \Net_IDNA2();
|
||||
$oIdn->setParams('utf8', true);
|
||||
}
|
||||
|
||||
return $oIdn;
|
||||
|
|
@ -2441,7 +2442,7 @@ END;
|
|||
*/
|
||||
public static function IdnToUtf8($sStr, $bLowerIfAscii = false)
|
||||
{
|
||||
if (0 < \strlen($sStr) && \preg_match('/(^|\.)xn--/i', $sStr))
|
||||
if (0 < \strlen($sStr) && \preg_match('/(^|\.|@)xn--/i', $sStr))
|
||||
{
|
||||
try
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue