std.crypto.ecc.Secp256k1.add
pub fn add(p: Secp256k1, q: Secp256k1) Secp256k1
- Kind
- function
- Module
std.crypto.ecc.Secp256k1
Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
The entries of std.crypto.ecc.Secp256k1 in the Zig reference. This page has 27 cards.
pub fn add(p: Secp256k1, q: Secp256k1) Secp256k1
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn addMixed(p: Secp256k1, q: AffineCoordinates) Secp256k1
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn affineCoordinates(p: Secp256k1) AffineCoordinates
Return affine coordinates.
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
The secp256k1 base point.
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn dbl(p: Secp256k1) Secp256k1
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn splitScalar(s: [32]u8, endian: std.lang.Endian) NonCanonicalError!SplitScalar
Compute r1 and r2 so that k = r1 + r2*lambda (mod L).
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn equivalent(a: Secp256k1, b: Secp256k1) bool
Return true if both coordinate sets represent the same point.
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn fromAffineCoordinates(p: AffineCoordinates) EncodingError!Secp256k1
Create a point from affine coordinates after checking that they match the curve equation.
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn fromSec1(s: []const u8) (EncodingError || NotSquareError || NonCanonicalError)!Secp256k1
Deserialize a SEC1-encoded point.
std.crypto.ecc.Secp256k1Source: 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.lang.Endian) (NonCanonicalError || EncodingError)!Secp256k1
Create a point from serialized affine coordinates.
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
The secp256k1 neutral element.
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn mul(p: Secp256k1, s_: [32]u8, endian: std.lang.Endian) IdentityElementError!Secp256k1
Multiply an elliptic curve point by a scalar.
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn mulDoubleBasePublic(p1: Secp256k1, s1: [32]u8, p2: Secp256k1, s2: [32]u8, endian: std.lang.Endian) IdentityElementError!Secp256k1
Double-base multiplication of public parameters - Compute (p1*s1)+(p2*s2) *IN VARIABLE TIME* This can be used for signature verification.
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn mulPublic(p: Secp256k1, s: [32]u8, endian: std.lang.Endian) (IdentityElementError || NonCanonicalError)!Secp256k1
Multiply an elliptic curve point by a *PUBLIC* scalar *IN VARIABLE TIME* This can be used for signature verification.
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn neg(p: Secp256k1) Secp256k1
Flip the sign of the X coordinate.
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn random(io: std.Io) Secp256k1
Return a random point.
std.crypto.ecc.Secp256k1Source: 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.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn rejectIdentity(p: Secp256k1) IdentityElementError!void
Reject the neutral element.
std.crypto.ecc.Secp256k1Source: 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.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn sub(p: Secp256k1, q: Secp256k1) Secp256k1
Subtract secp256k1 points.
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn subMixed(p: Secp256k1, q: AffineCoordinates) Secp256k1
Subtract secp256k1 points, the second being specified using affine coordinates.
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn toCompressedSec1(p: Secp256k1) [33]u8
Serialize a point using the compressed SEC-1 format.
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn toUncompressedSec1(p: Secp256k1) [65]u8
Serialize a point using the uncompressed SEC-1 format.
std.crypto.ecc.Secp256k1Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.