Skip to content
pubscout

elliptic

0.4.0, released 4 months ago by c0mm4nd.com

Pure Dart elliptic curve math for ECDSA, ECDH, key generation.

WASM-ready
$ flutter pub add elliptic
Source repository

What it does

Provides elliptic curve primitives, key generation, ECDH, and utilities for working with PEM keys. It is dependency‑free and supports multiple curves including secp256k1.

AI-written summary of version 0.4.0, based on the package's README and metadata. Report an inaccuracy

Use it when

  • Implementing ECDSA or ECDH in a pure Dart project
  • Generating key pairs for cryptographic protocols
  • Testing or prototyping elliptic‑curve based algorithms

Skip it when

  • Needing hardware‑accelerated crypto or native performance
  • Using a full cryptographic library that already includes curve support

Strengths

  • Pure Dart, no third‑party dependencies
  • Regular security updates and point validation
  • Supports many standard curves

Weaknesses

  • No native acceleration
  • Not a complete crypto stack (no signing, hashing, etc.)

Setup

Kind
Pure Dart
Effort
Low
Code generation
No
Direct dependencies
0
import 'package:elliptic/elliptic.dart';
var ec = getP256();
var priv = ec.generatePrivateKey();
var pub = priv.publicKey;
print('privateKey: 0x$priv');
print('publicKey: 0x$pub');

Alternatives

Packages that do the same job and could replace elliptic.

Works with

Packages commonly used together with elliptic: ones it builds on, ones built on it, and its own family.