BN_sqr function

  1. @RecordUse.new()
  2. @Native<Int Function(Pointer<BIGNUM>, Pointer<BIGNUM>, Pointer<BN_CTX>)>(ffi.Pointer<BIGNUM>, ffi.Pointer<BIGNUM>, ffi.Pointer<BN_CTX>)>(symbol: 'bssl_dart_BN_sqr')
int BN_sqr(
  1. Pointer<BIGNUM> r,
  2. Pointer<BIGNUM> a,
  3. Pointer<BN_CTX> ctx
)

BN_sqr sets |r| = |a|^2 (i.e. squares), where |r| may be the same pointer as |a|. Returns one on success and zero otherwise. This is more efficient than BN_mul(r, a, a, ctx).

Implementation

@meta.RecordUse()
@ffi.Native<
  ffi.Int Function(
    ffi.Pointer<BIGNUM>,
    ffi.Pointer<BIGNUM>,
    ffi.Pointer<BN_CTX>,
  )
>(symbol: 'bssl_dart_BN_sqr')
external int BN_sqr(
  ffi.Pointer<BIGNUM> r,
  ffi.Pointer<BIGNUM> a,
  ffi.Pointer<BN_CTX> ctx,
);