View Source Secp256k1.Guards (secp256k1 v0.4.1)

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

Link to this macro

is_bin_size(data, size)

View Source (macro)

Is binary of specific size

Link to this macro

is_compressed_pubkey(pubkey)

View Source (macro)

Is compressed pubkey (probably) - binary 33 bytes long

Link to this macro

is_ecdsa_sig(sig)

View Source (macro)

Is ECDSA signature (probably) - binary 64 bytes long

Is hash (probably) - binary 32 bytes long

Link to this macro

is_pubkey(pubkey)

View Source (macro)

Is any type of pubkey (probably)

Link to this macro

is_schnorr_sig(sig)

View Source (macro)

Is Schnorr signature (probably) - binary 64 bytes long

Link to this macro

is_seckey(seckey)

View Source (macro)

Is seckey (probably) - binary 32 bytes long

Link to this macro

is_uncompressed_pubkey(pubkey)

View Source (macro)

Is uncompressed pubkey (probably) - binary 65 bytes long

Link to this macro

is_xonly_pubkey(pubkey)

View Source (macro)

Is xonly pubkey (probably) - binary 32 bytes long