k256 0.10.0

secp256k1 elliptic curve library written in pure Rust with support for ECDSA signing/verification (including Ethereum-style signatures with public-key recovery), Elliptic Curve Diffie-Hellman (ECDH), and general purpose secp256k1 curve arithmetic useful for implementing arbitrary group-based protocols.
Documentation
[package]
name = "k256"
version = "0.10.0" # Also update html_root_url in lib.rs when bumping this
description = """
secp256k1 elliptic curve library written in pure Rust with support for ECDSA
signing/verification (including Ethereum-style signatures with public-key
recovery), Elliptic Curve Diffie-Hellman (ECDH), and general purpose secp256k1
curve arithmetic useful for implementing arbitrary group-based protocols.
"""
authors = ["RustCrypto Developers"]
license = "Apache-2.0 OR MIT"
documentation = "https://docs.rs/elliptic-curve"
repository = "https://github.com/RustCrypto/elliptic-curves/tree/master/k256"
readme = "README.md"
categories = ["cryptography", "cryptography::cryptocurrencies", "no-std"]
keywords = ["bitcoin", "crypto", "ecc", "ethereum", "secp256k1"]
edition = "2021"
rust-version = "1.56"

[dependencies]
cfg-if = "1.0"
elliptic-curve = { version = "0.11.5", default-features = false, features = ["hazmat", "sec1"] }
sec1 = { version = "0.2", default-features = false }

# optional dependencies
ecdsa-core = { version = "0.13", package = "ecdsa", optional = true, default-features = false, features = ["der"] }
hex-literal = { version = "0.3", optional = true }
sha2 = { version = "0.9", optional = true, default-features = false }
sha3 = { version = "0.9", optional = true, default-features = false }

[dev-dependencies]
blobby = "0.3"
criterion = "0.3"
ecdsa-core = { version = "0.13", package = "ecdsa", default-features = false, features = ["dev"] }
hex-literal = "0.3"
num-bigint = "0.4"
num-traits = "0.2"
proptest = "1.0"
rand_core = { version = "0.6", features = ["getrandom"] }

[features]
default = ["arithmetic", "ecdsa", "pkcs8", "sha256", "std"]
arithmetic = ["elliptic-curve/arithmetic"]
bits = ["arithmetic", "elliptic-curve/bits"]
digest = ["ecdsa-core/digest", "ecdsa-core/hazmat"]
ecdh = ["arithmetic", "elliptic-curve/ecdh"]
ecdsa = ["arithmetic", "digest", "ecdsa-core/sign", "ecdsa-core/verify"]
expose-field = ["arithmetic"]
jwk = ["elliptic-curve/jwk"]
keccak256 = ["digest", "sha3"]
pem = ["elliptic-curve/pem", "ecdsa-core/pem", "pkcs8"]
pkcs8 = ["elliptic-curve/pkcs8"]
serde = ["ecdsa-core/serde", "elliptic-curve/serde", "sec1/serde"]
sha256 = ["digest", "sha2"]
std = ["ecdsa-core/std", "elliptic-curve/std"] # TODO: use weak activation for `ecdsa-core/std` when available
test-vectors = ["hex-literal"]

[package.metadata.docs.rs]
features = ["ecdh", "ecdsa", "sha256", "keccak256"]
rustdoc-args = ["--cfg", "docsrs"]

[[bench]]
name = "ecdsa"
path = "bench/ecdsa.rs"
harness = false
required-features = ["ecdsa", "sha256"]

[[bench]]
name = "field"
path = "bench/field.rs"
harness = false
required-features = ["expose-field"]

[[bench]]
name = "scalar"
path = "bench/scalar.rs"
harness = false