On a side note, the currently implemented From<&Certificate> (and the other way around) in the openssl implementation are wrong. Cloning should not be done implicitly inside From implementation.
Referencing #356, I think this code can definitively be improved
https://github.com/virtee/sev/blob/c0a3feb737bd53810eb05320210d06d2adcd2944/src/certs/snp/cert.rs#L56C1-L60C2