Improving handling of libsodium and security features