Commit dde2c82
fuzz: fix ChaCha20 encrypt_single_block to preserve data
The fuzzing ChaCha20 implementation's encrypt_single_block was not
copying src to dest, causing encrypted data to be lost (dest remained
zeros). This broke payment flows where metadata is encrypted into
payment_secret - the receiver would decrypt zeros and detect the wrong
payment method (LdkPaymentHash instead of UserPaymentHash), causing
payments to fail with "mismatching preimage".
Fix by making encrypt_single_block copy src to dest (identity
encryption), matching the behavior of the process() method.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>1 parent 7fcfb39 commit dde2c82
1 file changed
Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
321 | 321 | | |
322 | 322 | | |
323 | 323 | | |
| 324 | + | |
324 | 325 | | |
325 | 326 | | |
326 | 327 | | |
| |||
0 commit comments