• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

lightningnetwork / lnd / 13035292482

29 Jan 2025 03:59PM UTC coverage: 49.3% (-9.5%) from 58.777%
13035292482

Pull #9456

github

mohamedawnallah
docs: update release-notes-0.19.0.md

In this commit, we warn users about the removal
of RPCs `SendToRoute`, `SendToRouteSync`, `SendPayment`,
and `SendPaymentSync` in the next release 0.20.
Pull Request #9456: lnrpc+docs: deprecate warning `SendToRoute`, `SendToRouteSync`, `SendPayment`, and `SendPaymentSync` in Release 0.19

100634 of 204126 relevant lines covered (49.3%)

1.54 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/netann/msg_hash.go
1
package netann
2

3
import (
4
        "github.com/btcsuite/btcd/chaincfg/chainhash"
5
)
6

7
// MsgHashTag will prefix the message name and the field name in order to
8
// construct the message tag.
9
const MsgHashTag = "lightning"
10

11
// MsgTag computes the full tag that will be used to prefix a message before
12
// calculating the tagged hash. The tag is constructed as follows:
13
//
14
//        tag = "lightning"||"msg_name"||"field_name"
15
func MsgTag(msgName, fieldName string) []byte {
×
16
        tag := []byte(MsgHashTag)
×
17
        tag = append(tag, []byte(msgName)...)
×
18

×
19
        return append(tag, []byte(fieldName)...)
×
20
}
×
21

22
// MsgHash computes the tagged hash of the given message as follows:
23
//
24
//        tag = "lightning"||"msg_name"||"field_name"
25
//        hash = sha256(sha246(tag) || sha256(tag) || msg)
26
func MsgHash(msgName, fieldName string, msg []byte) *chainhash.Hash {
×
27
        tag := MsgTag(msgName, fieldName)
×
28

×
29
        return chainhash.TaggedHash(tag, msg)
×
30
}
×
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc