`PaymentPurpose` in `Event::PaymentClaimed` missing preimage when using custom `PaymentHash`

Aberta
#4,270 1 comentário 0 reações 0 responsáveis Ver no GitHub

Ninguém assumiu esta issue ainda.

Avaliação

Dificuldade
4/5
Tempo estimado
3-5 dias
Facilidade para iniciantes
28/100
Tipo de issue
Bug
Clareza
Razoavelmente clara
Status de atividade
Estagnada
Stack de tecnologia
rust
Domínio
blockchain, payments

Direção de pesquisa

The report is about Event::PaymentClaimed after ChannelManager::claim_funds when the BOLT11 invoice used a custom PaymentHash: PaymentPurpose should carry Some(preimage) but stays None. Start from how claim_funds records the preimage and how PaymentClaimed / Bolt11InvoicePayment is built for that path versus LDK-generated hashes. Confirm done when PaymentClaimed includes payment_preimage: Some(preimage) for a custom-hash invoice. The thread is old and silent, so check whether the behavior already changed upstream before coding.

Escrita pelo modelo de indexação a partir do texto da issue.

Descrição

Description

When creating a BOLT11 invoice with a custom PaymentHash (instead of letting LDK generate one), the Event::PaymentClaimed event does not contain a PaymentPreimage inside the PaymentPurpose.

After calling ChannelManager::claim_funds() (where the preimage is provided by the application), LDK should then be aware of the preimage.

Expected Behavior

After calling claim_funds(preimage), the subsequent Event::PaymentClaimed should include PaymentPurpose::Bolt11InvoicePayment { payment_preimage: Some(preimage), .. } even when the invoice uses a custom PaymentHash.

Actual Behavior

payment_preimage is always None for Bolt11 payments with custom PaymentHash, even after the preimage has been supplied to LDK via claim_funds().

Linguagem predominante
Rust
Estrelas
1.4k
Forks
482
Métricas de merge de PRs
Nenhum PR com merge em 30d

Preparar o ambiente

Primeiros passos

  1. Leia a issue inteira e depois o guia de contribuição do projeto.
  2. Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
  3. Faça um fork do repositório e trabalhe em uma branch.
  4. Abra um pull request que referencie o número da issue.

Mais de lightningdevkit/rust-lightning

Todas as issues de lightningdevkit/rust-lightning

Issues semelhantes

Mais issues de Rust

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.