Note: You are currently viewing documentation for Moodle 4.3. Up-to-date documentation for the latest stable version of Moodle may be available here: Environment - PHP extension sodium.

Environment - PHP extension sodium

From MoodleDocs

The php-sodium extension provides strong encryption capabilities in an easy and consistent way. This extension is required from Moodle 4.2.

Note that it is still highly recommended to use php-sodium in Moodle 3.11, 4.0 and 4.1, which also support the extension. Sites which do not have this extension installed use a php-openssl based solution as a fallback, which is considered sub-optimal. See MDL-71421 for more details.

It might be useful to copy the \server\php\libsodium.dll library to \server\apache\bin\libsodium.dll - as mentioned in https://moodle.org/mod/forum/discuss.php?d=444514

See also https://www.php.net/manual/book.sodium.php and https://py-ipv8.readthedocs.io/en/latest/preliminaries/install_libsodium/