lightning-makesecret

lightning-makesecret -- Command for deriving pseudorandom key from HSM

SYNOPSIS

makesecret [hex] [string]

DESCRIPTION

The makesecret RPC command derives a secret key from the HSM_secret.

  • hex (hex, optional): One of hex or string must be specified: hex can be any hex data.
  • string (string, optional): One of hex or string must be specified: string is a UTF-8 string interpreted literally.

RETURN VALUE

On success, an object is returned, containing:

  • secret (secret): The pseudorandom key derived from HSM_secret.

ERRORS

The following error codes may occur:

  • -1: Catchall nonspecific error.

AUTHOR

Aditya <[email protected]> is mainly responsible.

RESOURCES

Main web site: https://github.com/ElementsProject/lightning

EXAMPLES

Example 1:

Request:

lightning-cli makesecret "73636220736563726574"
{
  "id": "example:makesecret#1",
  "method": "makesecret",
  "params": [
    "73636220736563726574"
  ]
}

Response:

{
  "secret": "82d3e65651ac89124448cb88b5f4cd009f6c321f58ada0fca6e9e3f2d1c5889e"
}

Example 2:

Request:

lightning-cli makesecret -k "string"="scb secret"
{
  "id": "example:makesecret#2",
  "method": "makesecret",
  "params": {
    "string": "scb secret"
  }
}

Response:

{
  "secret": "82d3e65651ac89124448cb88b5f4cd009f6c321f58ada0fca6e9e3f2d1c5889e"
}

Core Lightning (previously c-lightning) is a lightweight, highly customizable and standard compliant implementation of the Lightning Network protocol.

© 2023 Core Lightning
All rights reserved.

Discussion Forum

The official Core Lightning forum is hosted at discuss.corelightning.org

BuildonL2 Community

The official BuildOnL2 community lives at community.corelightning.org. Join us and build the future of bitcoin on lightning.

Mailing List

For general discussions about CLN implementation, use [email protected]. For the Lightning Network, use [email protected]

Telegram

Community-driven telegram group where most of the node operators hang out. Go to https://t.me/lightningd to join.

Discord

Community-driven discord server where the devs flock together. Go to https://discord.gg/w27fMFESMN to join.

Internet Relay Chat

Don't hesitate to reach out to us on IRC at #lightning-dev @ libera.chat, #c-lightning @ libera.chat.