Secp256k1.Guards (secp256k1 v0.6.1)

View Source

Common guards for secp256k1 functions

Summary

Functions

Is binary of specific size

Is compressed pubkey (probably) - binary 33 bytes long

Is ECDSA signature (probably) - binary 64 bytes long

Is hash (probably) - binary 32 bytes long

Is any type of pubkey (probably)

Is Schnorr signature (probably) - binary 64 bytes long

Is seckey (probably) - binary 32 bytes long

Is uncompressed pubkey (probably) - binary 65 bytes long

Is xonly pubkey (probably) - binary 32 bytes long

Functions

is_bin_size(data, size)

(macro)

Is binary of specific size

is_compressed_pubkey(pubkey)

(macro)

Is compressed pubkey (probably) - binary 33 bytes long

is_ecdsa_sig(sig)

(macro)

Is ECDSA signature (probably) - binary 64 bytes long

is_hash(data)

(macro)

Is hash (probably) - binary 32 bytes long

is_pubkey(pubkey)

(macro)

Is any type of pubkey (probably)

is_schnorr_sig(sig)

(macro)

Is Schnorr signature (probably) - binary 64 bytes long

is_seckey(seckey)

(macro)

Is seckey (probably) - binary 32 bytes long

is_uncompressed_pubkey(pubkey)

(macro)

Is uncompressed pubkey (probably) - binary 65 bytes long

is_xonly_pubkey(pubkey)

(macro)

Is xonly pubkey (probably) - binary 32 bytes long