AttributeError: function/symbol 'EVP_PKEY_size' not found in library 'libcrypto.so.3': /lib/x86_64-linux-gnu/libcrypto.so.3: undefined symbol: EVP_PKEY_size
According to this upstream issue, this is an OpenSSL 3.0 incompatibility that was fixed and appears to be available in the upstream 1.3.0 release. I think the principle fix would be: https://github.com/wbond/oscrypto/commit/e07413184f8038aa82c421350f4e49d1073f1491 However, https://github.com/wbond/oscrypto/commits/master shows followup commits dcd19aa, f533aff, etc. to improve things, so e0741318 alone may not adequately fix things.