I am able to sign and verify an ECDSA signature with the commands:
openssl dgst -sha256 -sign privateKey.pem data.txt > sign_data,txt
openssl dgst -sha256 -verify publicKey.pem -signature sign_data.txt data.txt
The output for the verification command is:
Verified OK
However, when I am sending my signed request to the server, I am getting an error saying that my signature was invalid. In my application, I am calling the above sign commands and then I am reading the signature (using python) as:
signature = open('sign_data.txt','rb').read()
Given these circumstances, can I be sure that there is no problem with the signature value and that another processing error occurred. In other words, could it be possible that the receiver can still reject a signature even if the above openssl passed the tests?