Running on Ubuntu 20.04.6 I am no longer able to run cargo ( or rustup ), am getting the above error.
I don't THINK I did anything, it was working before, not sure what could have caused this.
I looked at some stackexchange fixes, but they didn't seem to work ( or explain what the error means, why it can happen ).
Ubuntu 20.04 is very old and outdated, I would guess that it doesn't have a new enough OpenSSL (libssl) after upgrading rustup or cargo any more. Consider upgrading to 22.04 (current LTS). 24.04 (the next LTS) will be released later this spring.
Maybe there is a backport or package you could install, not sure.
Thanks. It turned out that
sudo apt update
sudo apt upgrade
was enough to get it working again. I guess you are right, I probably did update Rust a few days ago but didn't check it was working afterwards and only just noticed.