@@ -411,13 +411,17 @@ pub trait KeysInterface {
411
411
///
412
412
/// This method must return the same value each time it is called with a given `Recipient`
413
413
/// parameter.
414
+ ///
415
+ /// Errors if the `Recipient` variant is not supported by the implementation.
414
416
fn get_node_secret ( & self , recipient : Recipient ) -> Result < SecretKey , ( ) > ;
415
417
/// Get node id based on the provided [`Recipient`]. This public key corresponds to the secret in
416
418
/// [`get_node_secret`].
417
419
///
418
420
/// This method must return the same value each time it is called with a given `Recipient`
419
421
/// parameter.
420
422
///
423
+ /// Errors if the `Recipient` variant is not supported by the implementation.
424
+ ///
421
425
/// [`get_node_secret`]: KeysInterface::get_node_secret
422
426
fn get_node_id ( & self , recipient : Recipient ) -> Result < PublicKey , ( ) > {
423
427
let secp_ctx = Secp256k1 :: signing_only ( ) ;
@@ -427,6 +431,8 @@ pub trait KeysInterface {
427
431
/// one is provided. Note that this tweak can be applied to `other_key` instead of our node
428
432
/// secret, though this is less efficient.
429
433
///
434
+ /// Errors if the `Recipient` variant is not supported by the implementation.
435
+ ///
430
436
/// [`node secret`]: Self::get_node_secret
431
437
fn ecdh ( & self , recipient : Recipient , other_key : & PublicKey , tweak : Option < & Scalar > ) -> Result < SharedSecret , ( ) > ;
432
438
/// Get a script pubkey which we send funds to when claiming on-chain contestable outputs.
@@ -466,6 +472,8 @@ pub trait KeysInterface {
466
472
/// The hrp is ascii bytes, while the invoice data is base32.
467
473
///
468
474
/// The secret key used to sign the invoice is dependent on the [`Recipient`].
475
+ ///
476
+ /// Errors if the `Recipient` variant is not supported by the implementation.
469
477
fn sign_invoice ( & self , hrp_bytes : & [ u8 ] , invoice_data : & [ u5 ] , receipient : Recipient ) -> Result < RecoverableSignature , ( ) > ;
470
478
471
479
/// Get secret key material as bytes for use in encrypting and decrypting inbound payment data.
0 commit comments