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

Function pubkey_from_der

bitcoin/pubkey.c:14–24  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

12#endif
13
14bool pubkey_from_der(const u8 *der, size_t len, struct pubkey *key)
15{
16 if (len != PUBKEY_CMPR_LEN)
17 return false;
18
19 if (!secp256k1_ec_pubkey_parse(secp256k1_ctx, &key->pubkey,
20 memcheck(der, len), len))
21 return false;
22
23 return true;
24}
25
26void pubkey_to_der(u8 der[PUBKEY_CMPR_LEN], const struct pubkey *key)
27{

Callers 11

pubkey_from_hexstrFunction · 0.85
fromwire_pubkeyFunction · 0.85
test_wallet_outputsFunction · 0.85
test_channel_crudFunction · 0.85
stub_chanFunction · 0.85
set_pubkeyFunction · 0.85
db_col_pubkeyFunction · 0.85
decompressFunction · 0.85
sqlite3_column_pubkeyFunction · 0.85

Calls

no outgoing calls

Tested by 5

test_wallet_outputsFunction · 0.68
test_channel_crudFunction · 0.68
set_pubkeyFunction · 0.68