[−][src]Crate p256
NIST P-256 elliptic curve (a.k.a. prime256v1, secp256r1)
⚠️ Security Warning
The elliptic curve arithmetic contained in this crate has never been independently audited!
This crate has been designed with the goal of ensuring that secret-dependent
operations are performed in constant time (using the subtle
crate and
constant-time formulas). However, it has not been thoroughly assessed to ensure
that generated assembly is constant time on common CPU architectures.
USE AT YOUR OWN RISK!
About NIST P-256
NIST P-256 is a Weierstrass curve specified in FIPS 186-4: Digital Signature Standard (DSS):
https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.186-4.pdf
Also known as prime256v1 (ANSI X9.62) and secp256r1 (SECG), it's included in the US National Security Agency's "Suite B" and is widely used in protocols like TLS and the associated X.509 PKI.
Minimum Supported Rust Version
Rust 1.41 or higher.
Minimum supported Rust version can be changed in the future, but it will be done with a minor version bump.
Re-exports
pub use elliptic_curve; |
Modules
ecdh | feature="ecdh" Elliptic Curve Diffie-Hellman (Ephemeral) Support. |
ecdsa | feature="ecdsa-core" Elliptic Curve Digital Signature Algorithm (ECDSA) |
test_vectors | feature="test-vectors" secp256r1 test vectors. |
Structs
AffinePoint | feature="arithmetic" A point on the secp256r1 curve in affine coordinates. |
BlindedScalar | feature="arithmetic" and feature="rand" Scalar blinded with a randomly generated masking value. |
NistP256 | NIST P-256 elliptic curve. |
ProjectivePoint | feature="arithmetic" A point on the secp256r1 curve in projective coordinates. |
Scalar | feature="arithmetic" An element in the finite field modulo n. |
Type Definitions
CompressedPoint | NIST P-256 Compressed Curve Point |
ElementBytes | NIST P-256 Serialized Field Element. |
NonZeroScalar | Non-zero scalar value. |
PublicKey | NIST P-256 Public Key |
SecretKey | NIST P-256 Secret Key |
UncompressedPoint | NIST P-256 Uncompressed Curve Point |