I'm trying to verify a RSA signed message, however, the API that I have access to in that environment only has encrypt and decrypt. I think I understand that verification and encryption with public key are similar. Actually, running the following seems to work:
openssl rsautl -sign -in clear -inkey private_key.pem -out signed openssl rsautl -encrypt -pubin -inkey public_key.pem -in signed -raw -hexdump
This second command will get the initial clear, padded (then I just need to unpad and verify that it matches the clear). However, the -raw is where I encounter an issue. As the signed message is the size of the key, I can't encrypt it (the API will refuse, as does openssl if you omit -raw).
I'm not sure on how to proceed. I feel that what I'm trying to do should be possible.