c - How to decrypt data using RSA public key? -
let me introduce problem, have *.crt file, contains der encoded x509 version 3 certificate. using asn1 der(libtomcrypt) decrypt data , save structure called x509v3 . have message m, encrypted signature of m -> s(rsa encrypted), , public key -> p located inside x509 certificate(subject public key field). first must decrypt s using public key p, problem can't find api this? looked libtomcrypt seems there no api takes public key( unsigned char * ) , encrypted data (also unsigned char *) , gives decrypted data( unsigned char *). thanks help! p.s. sorry english;) you 1 of countless victims of historical sloppy presentation of signatures, has created , still creates massive amounts of confusion. what have signature , want verify it. there exist several signature algorithms, , 1 of them called "rsa" because looks similar asymmetric encryption algorithm called similar. rough description of rsa signatures "you encrypt private key" (i.e. taking...