I have the following code:
ssh_key = paramiko.RSAKey.from_private_key_file(key_filename)
the key looks like this:
-----BEGIN OPENSSH PRIVATE KEY-----
b3BlbnNzaC1rZXktdjEAAAAABG5vbmUAAAAEbm9uZQAAAAAAAAABAAABFwAAAAdzc2gtcn
NhAAAAAwEAAQAAAQEAqdgmJ2AQlmvpCsDWjbpIvIrx4AwtKn2t10wmGZIN9pqcJgQpo3HD
and is valid:
$ ssh-keygen -l -f <mykeyfile>
$ 2048 SHA256:x8jlUAObU3q2KXRtuGpxwhnGvB/ZoeD2IUqSA1OkCmI thomas@Thomas-MBP-2017 (RSA)
but I get the the following error:
not a valid RSA private key file
This is on MacOS, Python 2.7, Paramiko 2.4.2
What am I doing wrong?