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

Function derive_revocation_basepoint

common/derive_basepoints.c:214–231  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

212}
213
214bool derive_revocation_basepoint(const struct secret *seed,
215 struct pubkey *revocation_basepoint,
216 struct secret *revocation_secret)
217{
218 struct keys keys;
219
220 derive_keys(seed, &keys);
221
222 if (revocation_basepoint) {
223 if (!pubkey_from_privkey(&keys.r, revocation_basepoint))
224 return false;
225 }
226
227 if (revocation_secret)
228 *revocation_secret = keys.r.secret;
229
230 return true;
231}
232
233bool derive_htlc_basepoint(const struct secret *seed,
234 struct pubkey *htlc_basepoint,

Callers 2

mainFunction · 0.85

Calls 2

pubkey_from_privkeyFunction · 0.85
derive_keysFunction · 0.70

Tested by 1

mainFunction · 0.68