MCPcopy Create free account
hub / github.com/ElementsProject/lightning / pubkey_to_der

Function pubkey_to_der

bitcoin/pubkey.c:26–34  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

24}
25
26void pubkey_to_der(u8 der[PUBKEY_CMPR_LEN], const struct pubkey *key)
27{
28 size_t outlen = PUBKEY_CMPR_LEN;
29 if (!secp256k1_ec_pubkey_serialize(secp256k1_ctx, der, &outlen,
30 &key->pubkey,
31 SECP256K1_EC_COMPRESSED))
32 abort();
33 assert(outlen == PUBKEY_CMPR_LEN);
34}
35
36bool pubkey_from_secret(const struct secret *secret, struct pubkey *key)
37{

Callers 15

add_push_keyFunction · 0.70
stack_keyFunction · 0.70
pubkey_to_hexstrFunction · 0.70
pubkey_cmpFunction · 0.70
pubkey_to_hash160Function · 0.70
psbt_input_add_pubkeyFunction · 0.70
psbt_input_set_signatureFunction · 0.70
steal_htlcFunction · 0.50
commit_number_obscurerFunction · 0.50
serialize_onionpacketFunction · 0.50
compute_blinding_factorFunction · 0.50
generate_hop_paramsFunction · 0.50

Calls 1

abortFunction · 0.85

Tested by

no test coverage detected