EVP_Digest function

  1. @RecordUse.new()
  2. @Native<Int Function(Pointer<Void>, Size, Pointer<Uint8>, Pointer<UnsignedInt>, Pointer<EVP_MD>, Pointer<ENGINE>)>(ffi.Pointer<ffi.Void>, ffi.Size, ffi.Pointer<ffi.Uint8>, ffi.Pointer<ffi.UnsignedInt>, ffi.Pointer<EVP_MD>, ffi.Pointer<ENGINE>)>(symbol: 'bssl_dart_EVP_Digest')
int EVP_Digest(
  1. Pointer<Void> data,
  2. int len,
  3. Pointer<Uint8> md_out,
  4. Pointer<UnsignedInt> md_out_size,
  5. Pointer<EVP_MD> type,
  6. Pointer<ENGINE> impl,
)

EVP_Digest performs a complete hashing operation in one call. It hashes |len| bytes from |data| and writes the digest to |md_out|. |EVP_MD_CTX_size| bytes are written, which is at most |EVP_MAX_MD_SIZE|. If |out_size| is not NULL then |*out_size| is set to the number of bytes written. It returns one on success and zero otherwise.

Implementation

@meta.RecordUse()
@ffi.Native<
  ffi.Int Function(
    ffi.Pointer<ffi.Void>,
    ffi.Size,
    ffi.Pointer<ffi.Uint8>,
    ffi.Pointer<ffi.UnsignedInt>,
    ffi.Pointer<EVP_MD>,
    ffi.Pointer<ENGINE>,
  )
>(symbol: 'bssl_dart_EVP_Digest')
external int EVP_Digest(
  ffi.Pointer<ffi.Void> data,
  int len,
  ffi.Pointer<ffi.Uint8> md_out,
  ffi.Pointer<ffi.UnsignedInt> md_out_size,
  ffi.Pointer<EVP_MD> type,
  ffi.Pointer<ENGINE> impl,
);