Open rwv37 opened 5 months ago
I was unable to reproduce this failure. Here's what I did:
ssh-keygen -f mykey # creates mykey and mykey.pub
ssh-keygen -s mykey -I 1234 mykey.pub # creates mykey-cert.pub
ln -s mykey-cert.pub mykey-cert-symlink.pub
Both step ssh inspect mykey-cert.pub
and step ssh inspect mykey-cert-symlink.pub
work, and generate the same output. I tried this on both macOS and on Ubuntu.
@rwv37 Can you check if it works for you with these commands? This could be a FreeBSD-specific problem, but I'd have to set up a virtual machine to debug this further, so I'd like to check this first. If it does work, can you share how you create *.pub SSH file that leads to the crash?
@marten-seemann also try this, which is doing a slightly different thing (operating on the key, instead of the cert)
$ ln -s mykey.pub mykey-symlink.pub
$ step ssh inspect mykey.pub
error decoding ssh certificate: *ssh.rsaPublicKey is not an *ssh.Certificate
exit status 1
That is expected behavior, currently. It would be nice to print SSH public key info, but that's a different issue.
@rwv37 can you verify that the contents of the .pub
are the same if you read them directly and when through the symlink?
Steps to Reproduce
Make a *.pub SSH file. Make a symlink to it. Use
step ssh inspect
, specifying the symlink.Your Environment
step-ca
Version - 0.26.0Expected Behavior
I expected it to show information about the *.pub file.
Actual Behavior
It crashes. Stack trace:
Additional Context
It works fine if I specify the actual *.pub file rather than the symlink to it.
Contributing
Vote on this issue by adding a 👍 reaction. To contribute a fix for this issue, leave a comment (and link to your pull request, if you've opened one already).