Function gnunet_sys::GNUNET_CRYPTO_eddsa_verify_[][src]

pub unsafe extern "C" fn GNUNET_CRYPTO_eddsa_verify_(
    purpose: u32,
    validate: *const GNUNET_CRYPTO_EccSignaturePurpose,
    sig: *const GNUNET_CRYPTO_EddsaSignature,
    pub_: *const GNUNET_CRYPTO_EddsaPublicKey
) -> c_int

@ingroup crypto @brief Verify EdDSA signature.

The @a validate data is the beginning of the data of which the signature is to be verified. The size field in @a validate must correctly indicate the number of bytes of the data structure, including its header. If @a purpose does not match the purpose given in @a validate (the latter must be in big endian), signature verification fails. If possible, use #GNUNET_CRYPTO_eddsa_verify() instead of this function (only if @a validate is not fixed-size, you must use this function directly).

@param purpose what is the purpose that the signature should have? @param validate block to validate (size, purpose, data) @param sig signature that is being validated @param pub public key of the signer @returns #GNUNET_OK if ok, #GNUNET_SYSERR if invalid