This seems like it should be simple, but I'm getting confused.

I have a binary file which I've discovered contains two keys: A Master and a Sub.
I've been able to read the file as a byte array from the file system, then add it to the keyStore using the method:
I've verified that the key exists using:
which returns true. I can also delete the key from the keyStore using:
Now, I'd like to use the public key to encrypt a file, but I'm unable to get a reference to the Key using:
Is there something I'm missing?