Struggling to use the "assert" example: FIDO_ERR_NO_CREDENTIALS #863
-
I am trying to use the assert example, but it fails with I tried this: build/examples/assert -t eddsa -a ~/.ssh/id_ed25519_sk -P "<my FIDO pin>" /path/to/id_ed25519_sk.pub.pem /dev/hidraw7 Reading from the sources, I assumed that:
echo "-----BEGIN PUBLIC KEY-----" > id_ed25519_sk.pub.pem
openssl base64 -in ~/.ssh/id_ed25519_sk.pub >> id_ed25519_sk.pub.pem
echo "-----END PUBLIC KEY-----" >> id_ed25519_sk.pub.pem The example README also says that [-a cred_id] can be omitted for the resident key, but I get the same error when I omit it. What am I doing wrong? 😕 |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 6 replies
-
Hi, Are you trying to use an SSH credential with our examples? That will not work without further modifications due to several reasons:
If you extract the corresponding parts from the SSH key files, and recreate the expected input format, you could probably get a successful assertion using What are you trying to accomplish though? If you're just trying to figure out how our API works, I recommend looking at and using |
Beta Was this translation helpful? Give feedback.
Having limited experience with libgit2, I unfortunately don't know what that callback expects.
If you really want to try to get an assertion with our tooling instead of our library functions first, and really want to experiment with OpenSSH keys directly, here's an example of crudely extracting information out of the SSH private key file:
Let's have a look at the raw contents: