diff --git a/cmd/loop/loopin.go b/cmd/loop/loopin.go index 3f454de..d6d59bf 100644 --- a/cmd/loop/loopin.go +++ b/cmd/loop/loopin.go @@ -6,6 +6,7 @@ import ( "github.com/btcsuite/btcutil" "github.com/lightninglabs/loop" + "github.com/lightninglabs/loop/labels" "github.com/lightninglabs/loop/looprpc" "github.com/lightningnetwork/lnd/routing/route" "github.com/urfave/cli" @@ -24,6 +25,14 @@ var ( "confirm within", } + labelFlag = cli.StringFlag{ + Name: "label", + Usage: fmt.Sprintf("an optional label for this swap,"+ + "limited to %v characters. The label may not start "+ + "with our reserved prefix: %v.", + labels.MaxLength, labels.Reserved), + } + loopInCommand = cli.Command{ Name: "in", Usage: "perform an on-chain to off-chain swap (loop in)", @@ -51,6 +60,7 @@ var ( }, confTargetFlag, lastHopFlag, + labelFlag, }, Action: loopIn, } @@ -93,6 +103,12 @@ func loopIn(ctx *cli.Context) error { return fmt.Errorf("external and conf_target both set") } + // Validate our label early so that we can fail before getting a quote. + label := ctx.String(labelFlag.Name) + if err := labels.Validate(label); err != nil { + return err + } + quote, err := client.GetLoopInQuote( context.Background(), &looprpc.QuoteRequest{ @@ -133,6 +149,7 @@ func loopIn(ctx *cli.Context) error { MaxSwapFee: int64(limits.maxSwapFee), ExternalHtlc: external, HtlcConfTarget: htlcConfTarget, + Label: label, } if ctx.IsSet(lastHopFlag.Name) { diff --git a/cmd/loop/loopout.go b/cmd/loop/loopout.go index 59ac01b..be04053 100644 --- a/cmd/loop/loopout.go +++ b/cmd/loop/loopout.go @@ -9,6 +9,7 @@ import ( "github.com/btcsuite/btcutil" "github.com/lightninglabs/loop" + "github.com/lightninglabs/loop/labels" "github.com/lightninglabs/loop/looprpc" "github.com/urfave/cli" ) @@ -64,6 +65,7 @@ var loopOutCommand = cli.Command{ "Not setting this flag therefore might " + "result in a lower swap fee.", }, + labelFlag, }, Action: loopOut, } @@ -104,6 +106,12 @@ func loopOut(ctx *cli.Context) error { } } + // Validate our label early so that we can fail before getting a quote. + label := ctx.String(labelFlag.Name) + if err := labels.Validate(label); err != nil { + return err + } + var destAddr string switch { case ctx.IsSet("addr"): @@ -172,6 +180,7 @@ func loopOut(ctx *cli.Context) error { OutgoingChanSet: outgoingChanSet, SweepConfTarget: sweepConfTarget, SwapPublicationDeadline: uint64(swapDeadline.Unix()), + Label: label, }) if err != nil { return err diff --git a/interface.go b/interface.go index a1be6d6..46d88f0 100644 --- a/interface.go +++ b/interface.go @@ -74,6 +74,9 @@ type OutRequest struct { // Expiry is the absolute expiry height of the on-chain htlc. Expiry int32 + + // Label contains an optional label for the swap. + Label string } // Out contains the full details of a loop out request. This includes things @@ -186,6 +189,9 @@ type LoopInRequest struct { // ExternalHtlc specifies whether the htlc is published by an external // source. ExternalHtlc bool + + // Label contains an optional label for the swap. + Label string } // LoopInTerms are the server terms on which it executes loop in swaps. diff --git a/labels/labels.go b/labels/labels.go new file mode 100644 index 0000000..b2137f4 --- /dev/null +++ b/labels/labels.go @@ -0,0 +1,46 @@ +package labels + +import ( + "errors" +) + +const ( + // MaxLength is the maximum length we allow for labels. + MaxLength = 500 + + // Reserved is used as a prefix to separate labels that are created by + // loopd from those created by users. + Reserved = "[reserved]" +) + +var ( + // ErrLabelTooLong is returned when a label exceeds our length limit. + ErrLabelTooLong = errors.New("label exceeds maximum length") + + // ErrReservedPrefix is returned when a label contains the prefix + // which is reserved for internally produced labels. + ErrReservedPrefix = errors.New("label contains reserved prefix") +) + +// Validate checks that a label is of appropriate length and is not in our list +// of reserved labels. +func Validate(label string) error { + if len(label) > MaxLength { + return ErrLabelTooLong + } + + // If the label is shorter than our reserved prefix, it cannot contain + // it. + if len(label) < len(Reserved) { + return nil + } + + // Check if our label begins with our reserved prefix. We don't mind if + // it has our reserved prefix in another case, we just need to be able + // to reserve a subset of labels with this prefix. + if label[0:len(Reserved)] == Reserved { + return ErrReservedPrefix + } + + return nil +} diff --git a/labels/labels_test.go b/labels/labels_test.go new file mode 100644 index 0000000..6010d55 --- /dev/null +++ b/labels/labels_test.go @@ -0,0 +1,53 @@ +package labels + +import ( + "fmt" + "strings" + "testing" + + "github.com/stretchr/testify/require" +) + +// TestValidate tests validation of labels. +func TestValidate(t *testing.T) { + tests := []struct { + name string + label string + err error + }{ + { + name: "label ok", + label: "label", + err: nil, + }, + { + name: "exceeds limit", + label: strings.Repeat(" ", MaxLength+1), + err: ErrLabelTooLong, + }, + { + name: "exactly reserved prefix", + label: Reserved, + err: ErrReservedPrefix, + }, + { + name: "starts with reserved prefix", + label: fmt.Sprintf("%v test", Reserved), + err: ErrReservedPrefix, + }, + { + name: "ends with reserved prefix", + label: fmt.Sprintf("test %v", Reserved), + err: nil, + }, + } + + for _, test := range tests { + test := test + + t.Run(test.name, func(t *testing.T) { + t.Parallel() + require.Equal(t, test.err, Validate(test.label)) + }) + } +} diff --git a/loopd/swapclient_server.go b/loopd/swapclient_server.go index 74c2d75..8ebb9d4 100644 --- a/loopd/swapclient_server.go +++ b/loopd/swapclient_server.go @@ -89,6 +89,7 @@ func (s *swapClientServer) LoopOut(ctx context.Context, SwapPublicationDeadline: time.Unix( int64(in.SwapPublicationDeadline), 0, ), + Label: in.Label, } switch { @@ -214,6 +215,7 @@ func (s *swapClientServer) marshallSwap(loopSwap *loop.SwapInfo) ( CostServer: int64(loopSwap.Cost.Server), CostOnchain: int64(loopSwap.Cost.Onchain), CostOffchain: int64(loopSwap.Cost.Offchain), + Label: loopSwap.Label, }, nil } @@ -478,6 +480,7 @@ func (s *swapClientServer) LoopIn(ctx context.Context, MaxSwapFee: btcutil.Amount(in.MaxSwapFee), HtlcConfTarget: htlcConfTarget, ExternalHtlc: in.ExternalHtlc, + Label: in.Label, } if in.LastHop != nil { lastHop, err := route.NewVertexFromBytes(in.LastHop) diff --git a/loopdb/loop.go b/loopdb/loop.go index 870df9f..51ce917 100644 --- a/loopdb/loop.go +++ b/loopdb/loop.go @@ -43,6 +43,9 @@ type SwapContract struct { // InitiationTime is the time at which the swap was initiated. InitiationTime time.Time + + // Label contains an optional label for the swap. + Label string } // Loop contains fields shared between LoopIn and LoopOut diff --git a/loopdb/loopin.go b/loopdb/loopin.go index 409d679..756656c 100644 --- a/loopdb/loopin.go +++ b/loopdb/loopin.go @@ -6,6 +6,8 @@ import ( "fmt" "time" + "github.com/coreos/bbolt" + "github.com/lightninglabs/loop/labels" "github.com/lightningnetwork/lnd/routing/route" ) @@ -24,6 +26,10 @@ type LoopInContract struct { // ExternalHtlc specifies whether the htlc is published by an external // source. ExternalHtlc bool + + // Label contains an optional label for the swap. Note that this field + // is stored separately to the rest of the contract on disk. + Label string } // LoopIn is a combination of the contract and the updates. @@ -112,6 +118,31 @@ func serializeLoopInContract(swap *LoopInContract) ( return b.Bytes(), nil } +// putLabel performs validation of a label and writes it to the bucket provided +// under the label key if it is non-zero. +func putLabel(bucket *bbolt.Bucket, label string) error { + if len(label) == 0 { + return nil + } + + if err := labels.Validate(label); err != nil { + return err + } + + return bucket.Put(labelKey, []byte(label)) +} + +// getLabel attempts to get an optional label stored under the label key in a +// bucket. If it is not present, an empty label is returned. +func getLabel(bucket *bbolt.Bucket) string { + label := bucket.Get(labelKey) + if label == nil { + return "" + } + + return string(label) +} + // deserializeLoopInContract deserializes the loop in contract from a byte slice. func deserializeLoopInContract(value []byte) (*LoopInContract, error) { r := bytes.NewReader(value) diff --git a/loopdb/store.go b/loopdb/store.go index 1d48904..b4a6fad 100644 --- a/loopdb/store.go +++ b/loopdb/store.go @@ -60,6 +60,15 @@ var ( // value: time || rawSwapState contractKey = []byte("contract") + // labelKey is the key that stores an optional label for the swap. If + // a swap was created before we started adding labels, or was created + // without a label, this key will not be present. + // + // path: loopInBucket/loopOutBucket -> swapBucket[hash] -> labelKey + // + // value: string label + labelKey = []byte("label") + // outgoingChanSetKey is the key that stores a list of channel ids that // restrict the loop out swap payment. // @@ -207,6 +216,9 @@ func (s *boltSwapStore) FetchLoopOutSwaps() ([]*LoopOut, error) { return err } + // Get our label for this swap, if it is present. + contract.Label = getLabel(swapBucket) + // Read the list of concatenated outgoing channel ids // that form the outgoing set. setBytes := swapBucket.Get(outgoingChanSetKey) @@ -352,6 +364,9 @@ func (s *boltSwapStore) FetchLoopInSwaps() ([]*LoopIn, error) { return err } + // Get our label for this swap, if it is present. + contract.Label = getLabel(swapBucket) + updates, err := deserializeUpdates(swapBucket) if err != nil { return err @@ -434,6 +449,10 @@ func (s *boltSwapStore) CreateLoopOut(hash lntypes.Hash, return err } + if err := putLabel(swapBucket, swap.Label); err != nil { + return err + } + // Write the outgoing channel set. var b bytes.Buffer for _, chanID := range swap.OutgoingChanSet { @@ -447,6 +466,11 @@ func (s *boltSwapStore) CreateLoopOut(hash lntypes.Hash, return err } + // Write label to disk if we have one. + if err := putLabel(swapBucket, swap.Label); err != nil { + return err + } + // Finally, we'll create an empty updates bucket for this swap // to track any future updates to the swap itself. _, err = swapBucket.CreateBucket(updatesBucketKey) @@ -485,6 +509,11 @@ func (s *boltSwapStore) CreateLoopIn(hash lntypes.Hash, return err } + // Write label to disk if we have one. + if err := putLabel(swapBucket, swap.Label); err != nil { + return err + } + // Finally, we'll create an empty updates bucket for this swap // to track any future updates to the swap itself. _, err = swapBucket.CreateBucket(updatesBucketKey) diff --git a/loopdb/store_test.go b/loopdb/store_test.go index d373876..bde8c25 100644 --- a/loopdb/store_test.go +++ b/loopdb/store_test.go @@ -83,6 +83,13 @@ func TestLoopOutStore(t *testing.T) { t.Run("two channel outgoing set", func(t *testing.T) { testLoopOutStore(t, &restrictedSwap) }) + + labelledSwap := unrestrictedSwap + labelledSwap.Label = "test label" + t.Run("labelled swap", func(t *testing.T) { + testLoopOutStore(t, &labelledSwap) + }) + } // testLoopOutStore tests the basic functionality of the current bbolt @@ -196,27 +203,6 @@ func testLoopOutStore(t *testing.T, pendingSwap *LoopOutContract) { // TestLoopInStore tests all the basic functionality of the current bbolt // swap store. func TestLoopInStore(t *testing.T) { - tempDirName, err := ioutil.TempDir("", "clientstore") - if err != nil { - t.Fatal(err) - } - defer os.RemoveAll(tempDirName) - - store, err := NewBoltSwapStore(tempDirName, &chaincfg.MainNetParams) - if err != nil { - t.Fatal(err) - } - - // First, verify that an empty database has no active swaps. - swaps, err := store.FetchLoopInSwaps() - if err != nil { - t.Fatal(err) - } - if len(swaps) != 0 { - t.Fatal("expected empty store") - } - - hash := sha256.Sum256(testPreimage[:]) initiationTime := time.Date(2018, 11, 1, 0, 0, 0, 0, time.UTC) // Next, we'll make a new pending swap that we'll insert into the @@ -243,6 +229,38 @@ func TestLoopInStore(t *testing.T) { ExternalHtlc: true, } + t.Run("loop in", func(t *testing.T) { + testLoopInStore(t, pendingSwap) + }) + + labelledSwap := pendingSwap + labelledSwap.Label = "test label" + t.Run("loop in with label", func(t *testing.T) { + testLoopInStore(t, labelledSwap) + }) +} + +func testLoopInStore(t *testing.T, pendingSwap LoopInContract) { + tempDirName, err := ioutil.TempDir("", "clientstore") + if err != nil { + t.Fatal(err) + } + defer os.RemoveAll(tempDirName) + + store, err := NewBoltSwapStore(tempDirName, &chaincfg.MainNetParams) + if err != nil { + t.Fatal(err) + } + + // First, verify that an empty database has no active swaps. + swaps, err := store.FetchLoopInSwaps() + if err != nil { + t.Fatal(err) + } + if len(swaps) != 0 { + t.Fatal("expected empty store") + } + // checkSwap is a test helper function that'll assert the state of a // swap. checkSwap := func(expectedState SwapState) { @@ -269,6 +287,8 @@ func TestLoopInStore(t *testing.T) { } } + hash := sha256.Sum256(testPreimage[:]) + // If we create a new swap, then it should show up as being initialized // right after. if err := store.CreateLoopIn(hash, &pendingSwap); err != nil { diff --git a/loopin.go b/loopin.go index 703974e..89777d9 100644 --- a/loopin.go +++ b/loopin.go @@ -13,6 +13,7 @@ import ( "github.com/btcsuite/btcd/chaincfg/chainhash" "github.com/btcsuite/btcd/wire" "github.com/lightninglabs/lndclient" + "github.com/lightninglabs/loop/labels" "github.com/lightninglabs/loop/loopdb" "github.com/lightninglabs/loop/swap" "github.com/lightningnetwork/lnd/chainntnfs" @@ -77,6 +78,11 @@ func newLoopInSwap(globalCtx context.Context, cfg *swapConfig, currentHeight int32, request *LoopInRequest) (*loopInInitResult, error) { + // Before we start, check that the label is valid. + if err := labels.Validate(request.Label); err != nil { + return nil, err + } + // Request current server loop in terms and use these to calculate the // swap fee that we should subtract from the swap amount in the payment // request that we send to the server. @@ -165,6 +171,7 @@ func newLoopInSwap(globalCtx context.Context, cfg *swapConfig, CltvExpiry: swapResp.expiry, MaxMinerFee: request.MaxMinerFee, MaxSwapFee: request.MaxSwapFee, + Label: request.Label, }, } diff --git a/loopout.go b/loopout.go index 5e26bc4..4f92ff5 100644 --- a/loopout.go +++ b/loopout.go @@ -13,6 +13,7 @@ import ( "github.com/btcsuite/btcd/wire" "github.com/btcsuite/btcutil" "github.com/lightninglabs/lndclient" + "github.com/lightninglabs/loop/labels" "github.com/lightninglabs/loop/loopdb" "github.com/lightninglabs/loop/swap" "github.com/lightninglabs/loop/sweep" @@ -87,6 +88,11 @@ type loopOutInitResult struct { func newLoopOutSwap(globalCtx context.Context, cfg *swapConfig, currentHeight int32, request *OutRequest) (*loopOutInitResult, error) { + // Before we start, check that the label is valid. + if err := labels.Validate(request.Label); err != nil { + return nil, err + } + // Generate random preimage. var swapPreimage [32]byte if _, err := rand.Read(swapPreimage[:]); err != nil { @@ -154,6 +160,7 @@ func newLoopOutSwap(globalCtx context.Context, cfg *swapConfig, CltvExpiry: request.Expiry, MaxMinerFee: request.MaxMinerFee, MaxSwapFee: request.MaxSwapFee, + Label: request.Label, }, OutgoingChanSet: chanSet, } diff --git a/looprpc/client.pb.go b/looprpc/client.pb.go index 6d4bc06..9a41679 100644 --- a/looprpc/client.pb.go +++ b/looprpc/client.pb.go @@ -237,10 +237,15 @@ type LoopOutRequest struct { //server the opportunity to batch multiple swaps together, and wait for //low-fee periods before publishing the HTLC, potentially resulting in a //lower total swap fee. - SwapPublicationDeadline uint64 `protobuf:"varint,10,opt,name=swap_publication_deadline,json=swapPublicationDeadline,proto3" json:"swap_publication_deadline,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` + SwapPublicationDeadline uint64 `protobuf:"varint,10,opt,name=swap_publication_deadline,json=swapPublicationDeadline,proto3" json:"swap_publication_deadline,omitempty"` + // + //An optional label for this swap. This field is limited to 500 characters + //and may not start with the prefix [reserved], which is used to tag labels + //produced by the daemon. + Label string `protobuf:"bytes,12,opt,name=label,proto3" json:"label,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` } func (m *LoopOutRequest) Reset() { *m = LoopOutRequest{} } @@ -346,6 +351,13 @@ func (m *LoopOutRequest) GetSwapPublicationDeadline() uint64 { return 0 } +func (m *LoopOutRequest) GetLabel() string { + if m != nil { + return m.Label + } + return "" +} + type LoopInRequest struct { //* //Requested swap amount in sat. This does not include the swap and miner @@ -374,7 +386,11 @@ type LoopInRequest struct { ExternalHtlc bool `protobuf:"varint,5,opt,name=external_htlc,json=externalHtlc,proto3" json:"external_htlc,omitempty"` //* //The number of blocks that the on chain htlc should confirm within. - HtlcConfTarget int32 `protobuf:"varint,6,opt,name=htlc_conf_target,json=htlcConfTarget,proto3" json:"htlc_conf_target,omitempty"` + HtlcConfTarget int32 `protobuf:"varint,6,opt,name=htlc_conf_target,json=htlcConfTarget,proto3" json:"htlc_conf_target,omitempty"` + // + //An optional label for this swap. This field is limited to 500 characters + //and may not be one of the reserved values in loop/labels Reserved list. + Label string `protobuf:"bytes,7,opt,name=label,proto3" json:"label,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` @@ -447,6 +463,13 @@ func (m *LoopInRequest) GetHtlcConfTarget() int32 { return 0 } +func (m *LoopInRequest) GetLabel() string { + if m != nil { + return m.Label + } + return "" +} + type SwapResponse struct { //* //Swap identifier to track status in the update stream that is returned from @@ -631,7 +654,9 @@ type SwapStatus struct { // On-chain transaction cost CostOnchain int64 `protobuf:"varint,9,opt,name=cost_onchain,json=costOnchain,proto3" json:"cost_onchain,omitempty"` // Off-chain routing fees - CostOffchain int64 `protobuf:"varint,10,opt,name=cost_offchain,json=costOffchain,proto3" json:"cost_offchain,omitempty"` + CostOffchain int64 `protobuf:"varint,10,opt,name=cost_offchain,json=costOffchain,proto3" json:"cost_offchain,omitempty"` + // An optional label given to the swap on creation. + Label string `protobuf:"bytes,15,opt,name=label,proto3" json:"label,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` @@ -762,6 +787,13 @@ func (m *SwapStatus) GetCostOffchain() int64 { return 0 } +func (m *SwapStatus) GetLabel() string { + if m != nil { + return m.Label + } + return "" +} + type ListSwapsRequest struct { XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` @@ -1467,120 +1499,122 @@ func init() { func init() { proto.RegisterFile("client.proto", fileDescriptor_014de31d7ac8c57c) } var fileDescriptor_014de31d7ac8c57c = []byte{ - // 1803 bytes of a gzipped FileDescriptorProto + // 1827 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x58, 0xdd, 0x6e, 0x23, 0x49, - 0x15, 0x1e, 0xff, 0xc5, 0xf6, 0x71, 0xbb, 0xdd, 0xa9, 0xec, 0x24, 0x8e, 0x19, 0x34, 0x9e, 0xde, + 0x15, 0x5e, 0xff, 0xc5, 0xf6, 0x71, 0xbb, 0xdd, 0xa9, 0xcc, 0x24, 0x8e, 0x19, 0x34, 0x9e, 0xde, 0x1d, 0xc8, 0x86, 0xd5, 0x98, 0xcd, 0x5e, 0xb1, 0x02, 0x24, 0x8f, 0xd3, 0xd9, 0x38, 0x4a, 0x6c, 0xd3, 0x76, 0x06, 0x2d, 0x42, 0x6a, 0x55, 0xec, 0x4a, 0xdc, 0xc2, 0xfd, 0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 0x79, 0x10, 0x62, 0xfa, 0x34, 0xbb, 0x2c, - 0xbf, 0x4f, 0x83, 0x90, 0x7c, 0x0c, 0x75, 0x76, 0x2b, 0x58, 0xe4, 0xd3, 0x85, 0x33, 0x17, 0x8b, - 0x29, 0xe6, 0xac, 0x62, 0x6b, 0x2b, 0xf0, 0x54, 0x2c, 0xa6, 0xe4, 0x00, 0x0c, 0x29, 0xcb, 0x04, - 0x64, 0x0b, 0x03, 0xa2, 0x4b, 0x7c, 0x1d, 0x0f, 0xf3, 0x9f, 0x39, 0xd0, 0xf0, 0x25, 0x31, 0x1e, - 0x06, 0x3e, 0x67, 0x84, 0x40, 0xde, 0x9d, 0xa1, 0x47, 0x55, 0x4c, 0x4c, 0xde, 0x9d, 0x49, 0x73, - 0xdc, 0x99, 0x73, 0x75, 0x27, 0x18, 0x47, 0x6b, 0x35, 0xbb, 0xec, 0xce, 0xde, 0xca, 0x4f, 0xf2, - 0x1a, 0x34, 0xbc, 0x89, 0xce, 0x66, 0x11, 0xe3, 0x5c, 0xbd, 0x61, 0x3c, 0x58, 0x93, 0x78, 0x57, - 0xc1, 0xe4, 0x0d, 0xec, 0xa4, 0x69, 0x8e, 0x1f, 0x1e, 0x7d, 0xe0, 0x73, 0xf4, 0xad, 0x6a, 0x6f, - 0xa7, 0x98, 0x03, 0x14, 0x90, 0xcf, 0x80, 0x64, 0xf8, 0x8a, 0x5e, 0x42, 0xba, 0x91, 0xa2, 0x8f, - 0x90, 0xfd, 0x1a, 0x74, 0xce, 0xa2, 0xf7, 0x2c, 0x72, 0x3c, 0xc6, 0x39, 0xbd, 0x61, 0xe8, 0x6c, - 0xd5, 0xae, 0x2b, 0xf4, 0x42, 0x81, 0xa6, 0x01, 0xfa, 0x45, 0xe0, 0xbb, 0x22, 0x88, 0xe2, 0xfc, - 0x99, 0x7f, 0x28, 0x02, 0x48, 0xef, 0xc7, 0x82, 0x8a, 0x25, 0x7f, 0xb0, 0x34, 0x65, 0x34, 0xf2, - 0x8f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 0x2f, + 0xad, 0x3d, 0xed, 0xc1, 0xd7, 0x50, 0x97, 0x77, 0xac, 0x3a, 0x3e, 0x4f, 0xbd, 0xe4, 0xcc, 0x58, + 0x69, 0xed, 0xdd, 0xc3, 0xb3, 0xd5, 0x41, 0x1a, 0x78, 0x05, 0xa7, 0xa2, 0xa3, 0x46, 0xc9, 0xd5, + 0x16, 0xfe, 0x17, 0xe2, 0x8b, 0xff, 0x04, 0x00, 0x00, 0xff, 0xff, 0x34, 0x6b, 0xfd, 0xc4, 0xbc, + 0x10, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. diff --git a/looprpc/client.proto b/looprpc/client.proto index 02eda34..f56da49 100644 --- a/looprpc/client.proto +++ b/looprpc/client.proto @@ -190,6 +190,13 @@ message LoopOutRequest { lower total swap fee. */ uint64 swap_publication_deadline = 10; + + /* + An optional label for this swap. This field is limited to 500 characters + and may not start with the prefix [reserved], which is used to tag labels + produced by the daemon. + */ + string label = 12; } message LoopInRequest { @@ -232,6 +239,12 @@ message LoopInRequest { The number of blocks that the on chain htlc should confirm within. */ int32 htlc_conf_target = 6; + + /* + An optional label for this swap. This field is limited to 500 characters + and may not be one of the reserved values in loop/labels Reserved list. + */ + string label = 7; } message SwapResponse { @@ -351,6 +364,9 @@ message SwapStatus { // Off-chain routing fees int64 cost_offchain = 10; + + // An optional label given to the swap on creation. + string label = 15; } enum SwapType { diff --git a/looprpc/client.swagger.json b/looprpc/client.swagger.json index 8c01bc1..0e2ef26 100644 --- a/looprpc/client.swagger.json +++ b/looprpc/client.swagger.json @@ -411,6 +411,10 @@ "type": "integer", "format": "int32", "description": "*\nThe number of blocks that the on chain htlc should confirm within." + }, + "label": { + "type": "string", + "description": "An optional label for this swap. This field is limited to 500 characters\nand may not be one of the reserved values in loop/labels Reserved list." } } }, @@ -473,6 +477,10 @@ "type": "string", "format": "uint64", "description": "*\nThe latest time (in unix seconds) we allow the server to wait before\npublishing the HTLC on chain. Setting this to a larger value will give the\nserver the opportunity to batch multiple swaps together, and wait for\nlow-fee periods before publishing the HTLC, potentially resulting in a\nlower total swap fee." + }, + "label": { + "type": "string", + "description": "An optional label for this swap. This field is limited to 500 characters\nand may not start with the prefix [reserved], which is used to tag labels\nproduced by the daemon." } } }, @@ -683,6 +691,10 @@ "type": "string", "format": "int64", "title": "Off-chain routing fees" + }, + "label": { + "type": "string", + "description": "An optional label given to the swap on creation." } } },