1
0
Fork 0
mirror of https://github.com/lightning/bolts.git synced 2025-03-13 11:35:41 +01:00

fix code typo in 04 onion routing (#1225)

This commit is contained in:
Mattia Careddu 2025-02-10 09:14:36 +01:00 committed by GitHub
parent 6bbcf5f892
commit e96c3c59bb
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -854,7 +854,7 @@ func NewOnionPacket(paymentPath []*btcec.PublicKey, sessionKey *btcec.PrivateKey
// Our starting packet needs to be filled out with random bytes, we // Our starting packet needs to be filled out with random bytes, we
// generate some deterministically using the session private key. // generate some deterministically using the session private key.
paddingKey := generateKey("pad", sessionKey.Serialize() paddingKey := generateKey("pad", sessionKey.Serialize())
paddingBytes := generateCipherStream(paddingKey, routingInfoSize) paddingBytes := generateCipherStream(paddingKey, routingInfoSize)
copy(mixHeader[:], paddingBytes) copy(mixHeader[:], paddingBytes)