During the installation of Magento 2.3.2 an error appears when creating an admin account:

An abstract factory could not create an instance of magentoframeworkencryptionencryptor(alias: Magento\Framework\Encryption\Encryptor).

The PHP version is 7.2.3

enter image description here

Please help

  • did you try running setup again?
    – Mohit Rane
    Jul 9, 2019 at 10:37
  • Yes, three times
    – kubaJS
    Jul 9, 2019 at 10:38

1 Answer 1


You need to upgrade your libsodium version to match the requirement, which is version 1.0.13 or above.


$ sudo apt install php-libsodium


$ yum install php-pecl-libsodium2

Restart your web-server.

After installing libsodium, make sure that it is loaded:

$ php -i | grep libsodium
libsodium headers version => 1.0.17
libsodium library version => 1.0.17

If you get another error such as PHP Fatal error: sodium_init() in Unknown on line 0, you should try installing libsodium using PECL. But for now at least you should try installing it using apt/yum first.

  • It works, thanks for your help!
    – kubaJS
    Jul 17, 2019 at 9:03
  • Cool, glad to hear that! Jul 17, 2019 at 13:09

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.