SPIP 4.1.1 and PHP 8.0/PHP 8.1: HTTP ERROR 500

I have SPIP 4.1.1 and PHP 8.0/PHP 8.1.
I get HTTP ERROR 500 with PHP 8.1 and PHP 8.0 when I want to update plugins.
Changing back to PHP 7.4 gives the following error:
Execution error …/prive/skeletons/body.html | File […]/ecrire/src/Chiffrer/SpipCles.php Line 155: Undefined constant ‹ SODIUM_CRYPTO_SECRETBOX_KEYBYTES ›

Does anyone know how to fix this?

Hello Kamran

Make sure the Sodium extension is installed for PHP.