Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

Invalid MAC

  • jackyhoo
  • jackyhoo's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
11 months 1 day ago #243769 by jackyhoo
Invalid MAC was created by jackyhoo
Please help us help you and fill where relevant:
Your LimeSurvey version:5.3.5
Own server or LimeSurvey hosting:localhost
Survey theme/template:fruity
==================
When sending an invitation email, there was an error of 500 indicating Invalid MAC. May I ask how to solve it?SodiumExceptionInvalid MACC:\phpstudy_pro\WWW\cp\third_party\paragonie\sodium_compat\src\Crypto.php(1058)1046 );
1047 $verified = ParagonIE_Sodium_Core_Poly1305::onetimeauth_verify(
1048 $mac,
1049 $c,
1050 ParagonIE_Sodium_Core_Util::substr($block0, 0, 32)
1051 );
1052 if (!$verified) {
1053 try {
1054 ParagonIE_Sodium_Compat::memzero($subkey);
1055 } catch (SodiumException $ex) {
1056 $subkey = null;
1057 }
1058 throw new SodiumException('Invalid MAC');
1059 }
1060
1061 /** @var string $m - Decrypted message */
1062 $m = ParagonIE_Sodium_Core_Util::xorStrings(
1063 ParagonIE_Sodium_Core_Util::substr($block0, self::secretbox_xsalsa20poly1305_ZEROBYTES),
1064 ParagonIE_Sodium_Core_Util::substr($c, 0, self::secretbox_xsalsa20poly1305_ZEROBYTES)
1065 );
1066 if ($clen > self::secretbox_xsalsa20poly1305_ZEROBYTES) {
1067 // We had more than 1 block, so let's continue to decrypt the rest.
1068 $m .= ParagonIE_Sodium_Core_Salsa20::salsa20_xor_ic(
1069 ParagonIE_Sodium_Core_Util::substr(
1070 $c,



Stack Trace#0+
  C:\phpstudy_pro\WWW\cp\third_party\paragonie\sodium_compat\src\Compat.php(2343): ParagonIE_Sodium_Crypto::secretbox_open()#1+
  C:\phpstudy_pro\WWW\cp\application\core\LSSodium.php(139): ParagonIE_Sodium_Compat::crypto_secretbox_open()#2+
  C:\phpstudy_pro\WWW\cp\application\models\LSActiveRecord.php(384): LSSodium->decrypt("Gghs1e6uWCMBsbs3waQDmZCylLlym9HlJ7EvfrEAXyA=")#3+
  C:\phpstudy_pro\WWW\cp\application\core\LimeMailer.php(131): LSActiveRecord::decryptSingle("Gghs1e6uWCMBsbs3waQDmZCylLlym9HlJ7EvfrEAXyA=")#4+
  C:\phpstudy_pro\WWW\cp\application\core\LimeMailer.php(230): LimeMailer->__construct()#5+
  C:\phpstudy_pro\WWW\cp\application\controllers\admin\Tokens.php(1397): LimeMailer::getInstance(2)#6 unknown(0): Tokens->email(921475)#7+
  C:\phpstudy_pro\WWW\cp\framework\web\actions\CAction.php(115): ReflectionMethod->invokeArgs(Tokens, array("921475"))

Please Log in to join the conversation.

More
11 months 21 hours ago #243779 by jelo
Replied by jelo on topic Invalid MAC
You didn't provide any infos about the hosting environment. Localhost? To stuff you posted indicates a Windows OS.

The cryptoextension is triggering an error which,
The crpytoextension is used because the password in the mailserver credentials are stored encrypted.

I recommend to update LimeSurvey 5 (you use an old version) and check what exact PHP version you currently use and if the PHP extension libsodium is uptodate and enabled. Perhaps you need to update your windows webserver environment.

The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users

Please Log in to join the conversation.

  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
10 months 3 weeks ago #243870 by DenisChenu
Replied by DenisChenu on topic Invalid MAC
Maybe try to set again the password too ?

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.

Please Log in to join the conversation.

Lime-years ahead

Online-surveys for every purse and purpose