silc_pkcs_verify

SYNOPSIS

    SilcBool silc_pkcs_verify(SilcPublicKey public_key,
                              unsigned char *signature,
                              SilcUInt32 signature_len,
                              unsigned char *data,
                              SilcUInt32 data_len,
                              SilcBool compute_hash,
                              SilcHash hash);

DESCRIPTION

Verifies signature. The 'signature' is verified against the 'data'. If `compute_hash' hash is TRUE the `hash' will be used in verification. If `hash' is NULL, the hash algorithm to be used is retrieved from the signature. If it isn't present in the signature the default hash function is used. The `rng' is usually not needed and may be NULL.

This call cannot be used if `public_key' is accelerated. All accelerators are usually asynchronous and the function will return before the verification has been done. In this case the silc_pkcs_verify_async should be used.