1
0
mirror of https://github.com/lightning/bolts.git synced 2024-11-19 10:00:04 +01:00
Commit Graph

555 Commits

Author SHA1 Message Date
Landon Mutch
08f23a7515 BOLT 4: add packet forwarding requirements section 2017-12-14 02:07:36 +00:00
Rusty Russell
298489b421
BOLT 7: mention Tor hidden service. (#316)
* BOLT 7: mention Tor hidden service.

This is a common term to search for, rather than onion address (which is
what Tor hidden services use).

Reported-by: Alan Manuel K. Gloria <almkglor@gmail.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2017-12-14 02:06:28 +00:00
Jonathan Underwood
faee5ab6e7 Add signature related data in examples
This would have saved me a lot of time and pain. Sure, I should have realized that the document says something paradoxical (signature of the data part.... but the data part includes the signature..... so I should have guessed it meant "excluding the signature"...)

Explicit mention of the signature part might help people. Might not. But helps to be explicit.
2017-12-12 00:17:17 +00:00
Pierre-Marie Padiou
b46aa422dd do not print DEL character 2017-12-11 23:10:39 +00:00
Pierre-Marie Padiou
4e5ec11c4e add a check on counterparty's dust_limit value
Usually the counterparty would only hurt itself if it chooses too low a `dust_limit`, but in the specific scenario of a data loss, we want the counterparty's commitment tx to be relayed and confirmed on the network.
2017-12-11 23:01:34 +00:00
Rusty Russell
ef053c0943 BOLT 11: change route to base + millionths.
Doesn't take any more space (we could actually reduce millionths to 24 bits,
but that starts to look silly), but it's simpler and allows for cases where
there's no payment amount.

Closes: #296
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2017-12-11 23:00:45 +00:00
Olaoluwa Osuntokun
f4d2d62920 BOLT3: the closing transaction now uses version 2
In this commit, we modify the cooperative closing transaction to use
version 2. Currently eclair and lnd already use version 2, while
c-lightning uses version 1. The commitment transaction already uses
version 2, so making this additional transaction (which spends the
funding output) also use version 2 would be consistent. Additionally,
as a best practice, we should be using the highest currently
defined/use transaction version.
2017-12-11 22:58:56 +00:00
Rusty Russell
f1ac62c065 BOLT 5: fix reversed penalty HTLC handling clauses, make it clearer.
HTLC outputs can be resolved by (1) using revocation key,
(2) timeout/preimage use if that's possible, or (3) the cheating party's
HTLC-success/HTLC-timeout tx (which we also specify that you have to
spend using revocation key).

Hopefully this is now clearer.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2017-12-11 05:53:32 +00:00
RodneyNeilMorris
e64a738f62 Update 01-messaging.md
Clarified, wording to match that used in Requirements section.
2017-12-10 23:47:48 +00:00
Shannon Appelcline
0d74fd7b53 Lower-cased an "a". 2017-12-10 23:43:34 +00:00
Shannon Appelcline
978f3dfb01 Fix from #306
Added fix for duplicate word courtesy of @dimitris-t in #306.
2017-12-10 23:43:34 +00:00
Shannon Appelcline
130bc5da2c Responses to BOLT-8 Reviews
(1) addressed review items from @rustyrussell and @toadlyBroodle ; and (2) added table of contents courtesy of @bcongdon in #310
2017-12-10 23:43:34 +00:00
Shannon Appelcline
2b8b491c74 BOLT-8 Edits
More clarity and copyediting. I also removed quite a few `s that didn't seem to match general usage for "code".
2017-12-10 23:43:34 +00:00
Shannon Appelcline
27cc354c63 My final edits on these BOLT-7 changes 2017-12-10 23:42:21 +00:00
Shannon Appelcline
8fd6e4f66b Edits for BOLT-07 2017-12-10 23:42:21 +00:00
Shannon Appelcline
faba9241ac Manual rebase of Shannon's PR-294 rewrite.
This got a little messy as some changes now needed to be applied in
two places, and other wording has been completely removed.  Another
pass on top will be required.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2017-12-08 01:09:42 +00:00
Rusty Russell
433de81d24 BOLT 5: spell out each HTLC case.
The proof-readers rightly noted how confusing the current treatment of
HTLCs is.  There are four different cases, but I tried to address them
in two separate sections, with conditionals.

This expands it out, separating sections for Our Commitment Tx and
Their Commitment Tx, then subsections for our HTLCs and their HTLCs
in each one.

It means some duplicated requirements and rationales, but it should now
be very clear.

As a side effect, we no longer refer to A and B at all: it's all US and THEM.
This needs further clearing up, but for now makes it clear what *we* need to do
for all cases.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2017-12-08 01:09:42 +00:00
Landon Mutch
e840fdbded BOLT 4: couple last fixes and TODOs added 2017-12-07 02:36:10 +00:00
Landon Mutch
8165f28692 fix changes requested by @rustyrussell and @shannona in pr-299-rebased branch 2017-12-07 02:36:10 +00:00
Landon Mutch
aed4b11423 make spell check happy 2017-12-07 02:36:10 +00:00
Landon Mutch
54b49c09db BOLT 4: complete second-pass copy edit, introduced new terminology 'erring node', require a few clarifications 2017-12-07 02:36:10 +00:00
Landon Mutch
051f98a75e BOLT 4: second pass copy edit, update node terminology;
second pass copy edit to line 253, according to stylesheet
update node terminology to remove ambiguity; update conventions section and implement consistent usage of terms: origin node, final node, processing node, hop, sending peer, and receiving peer
2017-12-07 02:36:10 +00:00
Landon Mutch
4381f38279 BOLT 4: complete first pass copy edit by applying stylesheet guidelines 2017-12-07 02:36:10 +00:00
Landon Mutch
fe53690a9d BOLT 4: copy edit to line 735 2017-12-07 02:36:10 +00:00
Landon Mutch
a66fcf684c BOLT 4: first pass copy edit to line 600 2017-12-07 02:36:10 +00:00
Landon Mutch
94f717410f BOLT 4: first pass copy edit to line 366 2017-12-07 02:36:10 +00:00
Landon Mutch
7ce3341254 BOLT 4: apply stylesheet updates, first pass copy edit to line 128 2017-12-07 02:36:10 +00:00
Landon Mutch
5db55df16a BOLT 1,2,3: apply updated stylesheet guidelines for list capitalization, punctuation 2017-12-07 02:36:10 +00:00
Landon Mutch
4cc95f8190 BOLT 2: apply updated stylesheet guidelines for data measurements; 2017-12-07 02:36:10 +00:00
Landon Mutch
07f44a4419 BOLT 4: copy-edit, reword Overview 2017-12-07 02:36:10 +00:00
Landon Mutch
560ae85007 BOLT 4: add ToC, format headers 2017-12-07 02:36:10 +00:00
Dave Collins
42edacd9e7 BOLT 8: Fix current set typo. 2017-12-04 05:43:02 +00:00
Rusty Russell
add074bd2a Typo fixes as suggested by Landon Mutch.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2017-12-04 05:41:03 +00:00
Rusty Russell
31f6f1e53a fixup! minor indentation
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2017-12-04 05:41:03 +00:00
Shannon Appelcline
8b7873631f Updates for comments on pull. 2017-12-04 05:41:03 +00:00
Shannon Appelcline
0d8a1a20c4 BOLT-2 Edit
Some slightly larger scale revisions for BOLT-2, notably including a reorganization of the "open_channel" function with the introduction of two missing arguments.

Also, the addition of MSAT to the glossary in BOLT-0.
2017-12-04 05:41:03 +00:00
ueno
5989128977 HTLC maximum limit : 511 --> 483
0d7cf77970
2017-11-29 01:57:27 +00:00
Rusty Russell
be557e32a0 BOLT 1: options are no longer numbered.
I named the first option `option209` but that was too ugly to live.
Nonetheless, this wording lived on.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2017-11-28 23:12:20 +00:00
Rusty Russell
ce4b0f1c9e BOLT 2: which->that
Reported-by: Shannon Appelcline
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2017-11-28 23:11:55 +00:00
Landon Mutch
7a8a5d88dd BOLT 2,3: fix changes requested 2017-11-28 23:11:55 +00:00
Landon Mutch
cd3c49eb88 BOLT 3: fix typo 2017-11-28 23:11:55 +00:00
Landon Mutch
785d69de41 BOLT 3: complete first pass copy-edit according to stylesheet guidelines; 2017-11-28 23:11:55 +00:00
Landon Mutch
124626e693 BOLT 2: update stylesheet for numbers and amounts; 2017-11-28 23:11:55 +00:00
Landon Mutch
f23e3dd56b BOLT 1,2,3: first pass copy-edit;
BOLT 1,2: minor header spacing fixes
BOLT 3: first pass copy edit, according to capitalization, formatting stylesheet guidelines;
2017-11-28 23:11:55 +00:00
Landon Mutch
c00df17214 BOLT 0,2: update stylesheet, apply associated changes, 2nd pass copy-edit
BOLT 0: Update style sheet to reflect correct Bitcoin capitalizations
BOLT 2: Complete second pass copy-edit according to stylesheet guidelines
2017-11-28 23:11:55 +00:00
Rusty Russell
0c92bda566 BOLT 9: Adding missing option bits for option-dataloss-protect.
Somehow this got lost in merging; pre-approved at meeting 2017-11-27.

Reported-by: Pierre-Marie Padiou
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2017-11-28 23:03:12 +00:00
Rusty Russell
963b103113 BOLT 2: add precommitment to scriptpubkey for mutual close.
This is Fabrice's #243 "BOLT2, BOLT3: reduce attack surface", split
out with minor polishing:

- Made it an optional feature (we can insist on it if we choose even bit).
- Rename from "final_scriptpubkey" to "shutdown_scriptpubkey".
- Make requirements the same as shutdown's scriptpubkey, or zero-len.
- Leave shutdown's scriptpubkey, just make sure it's the same or fail.
- Add to accept_channel as well as open_channel.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2017-11-28 00:09:57 +00:00
Rusty Russell
005372c11a tools: don't enforce alignment.
It was always going to break when we started adding options, unless we
add padding.  As no implementation requires alignment, let's skip it.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2017-11-28 00:09:57 +00:00
Rusty Russell
4bb1d7e6be tools: allow `` around option names, strip them
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2017-11-28 00:09:57 +00:00
Rusty Russell
072a69fe77 BOLT 2: require that undefined bits in open_channel must be set to 0.
We already say that receiver has to ignore them.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2017-11-27 23:40:02 +00:00