std.crypto.ecc.P256.add
pub fn add(p: P256, q: P256) P256
- Kind
- function
- Module
std.crypto.ecc.P256
Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
The entries of std.crypto.ecc.P256 in the Zig reference. This page has 24 cards.
pub fn add(p: P256, q: P256) P256
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn addMixed(p: P256, q: AffineCoordinates) P256
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn affineCoordinates(p: P256) AffineCoordinates
Return affine coordinates.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
The P256 base point.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn dbl(p: P256) P256
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn equivalent(a: P256, b: P256) bool
Return true if both coordinate sets represent the same point.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn fromAffineCoordinates(p: AffineCoordinates) EncodingError!P256
Create a point from affine coordinates after checking that they match the curve equation.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn fromSec1(s: []const u8) (EncodingError || NotSquareError || NonCanonicalError)!P256
Deserialize a SEC1-encoded point.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn fromSerializedAffineCoordinates(xs: [32]u8, ys: [32]u8, endian: std.builtin.Endian) (NonCanonicalError || EncodingError)!P256
Create a point from serialized affine coordinates.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
The P256 neutral element.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn mul(p: P256, s_: [32]u8, endian: std.builtin.Endian) IdentityElementError!P256
Multiply an elliptic curve point by a scalar.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn mulDoubleBasePublic(p1: P256, s1_: [32]u8, p2: P256, s2_: [32]u8, endian: std.builtin.Endian) IdentityElementError!P256
Double-base multiplication of public parameters - Compute (p1*s1)+(p2*s2) *IN VARIABLE TIME* This can be used for signature verification.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn mulPublic(p: P256, s_: [32]u8, endian: std.builtin.Endian) IdentityElementError!P256
Multiply an elliptic curve point by a *PUBLIC* scalar *IN VARIABLE TIME* This can be used for signature verification.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn neg(p: P256) P256
Flip the sign of the X coordinate.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn random(io: std.Io) P256
Return a random point.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn recoverY(x: Fe, is_odd: bool) NotSquareError!Fe
Recover the Y coordinate from the X coordinate.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn rejectIdentity(p: P256) IdentityElementError!void
Reject the neutral element.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
Field arithmetic mod the order of the main subgroup.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn sub(p: P256, q: P256) P256
Subtract P256 points.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn subMixed(p: P256, q: AffineCoordinates) P256
Subtract P256 points, the second being specified using affine coordinates.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn toCompressedSec1(p: P256) [33]u8
Serialize a point using the compressed SEC-1 format.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn toUncompressedSec1(p: P256) [65]u8
Serialize a point using the uncompressed SEC-1 format.
std.crypto.ecc.P256Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.