Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bolt 1: Specify that extensions to existing messages must use TLV #754

Merged
merged 4 commits into from
Mar 31, 2020

Commits on Mar 2, 2020

  1. Bolt 1: Specify that extensions to existing messages must use TLV

    The spec already prepared a hook to add additional information to existing
    messages (additional bytes at the end of a message must be ignored).
    
    Since we're using TLV in many places, it makes sense to use that optional
    additional space at the end of each message to allow an optional tlv stream.
    
    This requires making a few previously optional fields mandatory:
    
    - channel_reestablish commitment points: it makes sense to always include those
      regardless of whether `option_dataloss_protect` or `option_static_remotekey` are set.
    - option_upfront_shutdown_script: if you're not using one, just set the length to 0.
      That field is moved to a TLV record because luckily, the resulting bytes are the same.
      This provides more flexibility to later remove the requirement of making this field mandatory.
    
    No need to change the `channel_update`'s `htlc_maximum_msat` because
    the `message_flags` encode its presence/absence.
    It can still be either included or omitted without causing issues to the extension stream.
    t-bast committed Mar 2, 2020
    Configuration menu
    Copy the full SHA
    6656b70 View commit details
    Browse the repository at this point in the history

Commits on Mar 12, 2020

  1. MAY close channels instead of MUST

    We don't need to be that strict and unforgiving.
    Let's give implementation the choice to simply close the connection.
    t-bast committed Mar 12, 2020
    Configuration menu
    Copy the full SHA
    70f1ed1 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    67b342d View commit details
    Browse the repository at this point in the history

Commits on Mar 17, 2020

  1. Extension not always possible for big packets

    Add a note that when a message payload already fills all the available
    bytes, it's not possible to add an extension.
    t-bast committed Mar 17, 2020
    Configuration menu
    Copy the full SHA
    a58cece View commit details
    Browse the repository at this point in the history