~ This returns the secret key for this node. */
| 283 | |
| 284 | /*~ This returns the secret key for this node. */ |
| 285 | static void node_schnorrkey(secp256k1_keypair *node_keypair) |
| 286 | { |
| 287 | struct privkey node_privkey; |
| 288 | |
| 289 | node_key(&node_privkey, NULL); |
| 290 | if (secp256k1_keypair_create(secp256k1_ctx, node_keypair, |
| 291 | node_privkey.secret.data) != 1) |
| 292 | hsmd_status_failed(STATUS_FAIL_INTERNAL_ERROR, |
| 293 | "Failed to derive keypair"); |
| 294 | } |
| 295 | |
| 296 | /*~ This secret is the basis for all per-channel secrets: the per-channel seeds |
| 297 | * will be generated by mixing in the dbid and the peer node_id. */ |
no test coverage detected