<?xml version='1.0' encoding='utf-8'?>
<!DOCTYPE rfc SYSTEM "rfc2629-xhtml.ent">
<rfc xmlns:xi="http://www.w3.org/2001/XInclude" category="std" docName="draft-ietf-idr-bgp-extended-messages-36" ipr="trust200902" updates="4271" obsoletes="" submissionType="IETF" xml:lang="en" sortRefs="true" symRefs="true" tocInclude="true" version="3">
  <!-- xml2rfc v2v3 conversion 2.27.0 -->
  <front>
    <title abbrev="Extended Message support for BGP">
           Extended Message support for BGP</title>
    <seriesInfo name="Internet-Draft" value="draft-ietf-idr-bgp-extended-messages-36"/>
    <author fullname="Randy Bush" initials="R." surname="Bush">
      <organization>Arrcus &amp; IIJ</organization>
      <address>
        <postal>
          <street>5147 Crystal Springs</street>
          <city>Bainbridge Island</city>
          <region>Washington</region>
          <code>98110</code>
          <country>US</country>
        </postal>
        <email>randy@psg.com</email>
      </address>
    </author>
    <author fullname="Keyur Patel" initials="K" surname="Patel">
      <organization>Arrcus, Inc.</organization>
      <address>
        <email>keyur@arrcus.com</email>
      </address>
    </author>
    <author fullname="Dave Ward" initials="D." surname="Ward">
      <organization>Cisco Systems</organization>
      <address>
        <postal>
          <street>170 W. Tasman Drive</street>
          <city>San Jose</city>
          <region>CA</region>
          <code>95134</code>
          <country>US</country>
        </postal>
        <email>dward@cisco.com</email>
      </address>
    </author>
    <date/>
    <abstract>
      <t>The BGP specification mandates a maximum BGP message size of 4,096
    octets.  As BGP is extended to support newer AFI/SAFIs and other
    features, there is a need to extend the maximum message size beyond
    4,096 octets.  This document updates the BGP specification RFC4271 by
    extending the maximum message size from 4,096 octets to 65,535 octets
    for all except the OPEN and KEEPALIVE messages.</t>
    </abstract>
    <note>
      <name>Requirements Language</name>
      <t>The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL
    NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED",
    "MAY", and "OPTIONAL" in this document are to be interpreted as
    described in BCP 14 <xref target="RFC2119" format="default"/> <xref target="RFC8174" format="default"/> when, and only when, they appear in all capitals,
    as shown here.</t>
    </note>
  </front>
  <middle>
    <section anchor="introduction" numbered="true" toc="default">
      <name>Introduction</name>
      <t>The BGP specification <xref target="RFC4271" format="default"/> mandates a maximum
    BGP message size of 4,096 octets.  As BGP is extended to support
    newer AFI/SAFIs and newer capabilities (e.g., BGPsec <xref target="RFC8205" format="default"/> and BGP-LS <xref target="RFC7752" format="default"/>), there is a
    need to extend the maximum message size beyond 4,096 octets. This
    draft provides an extension to BGP to extend its message size limit
    from 4,096 octets to 65,535 octets for all except the OPEN and
    KEEPALIVE messages.</t>
    </section>
    <section anchor="extmsg" numbered="true" toc="default">
      <name>BGP Extended Message</name>
      <t>A BGP message over 4,096 octets in length is a BGP Extended
    Message.</t>
      <t>BGP Extended Messages have a maximum message size of 65,535
    octets.  The smallest message that may be sent consists of a BGP
    KEEPALIVE which consists of 19 octets.</t>
    </section>
    <section numbered="true" toc="default">
      <name>Extended Message Capability for BGP</name>
      <t>The BGP Extended Message Capability is a new BGP Capability <xref target="RFC5492" format="default"/> defined with Capability code 6 and Capability
    length 0.</t>
      <t>To advertise the BGP Extended Message Capability to a peer, a BGP
    speaker uses BGP Capabilities Advertisement <xref target="RFC5492" format="default"/>.  By advertising the BGP Extended Message
    Capability to a peer, a BGP speaker conveys that it is able to
    receive and properly handle, see <xref target="opns" format="default"/>, BGP
    Extended Messages.</t>
      <t>Peers that wish to use the BGP Extended Message capability MUST
    support Error Handling for BGP UPDATE Messages per <xref target="RFC7606" format="default"/>.</t>
    </section>
    <section anchor="opns" numbered="true" toc="default">
      <name>Operation</name>
      <t>The Extended Message Capability applies to all messages except
    for the OPEN and KEEPALIVE messages.  The former exception is to
    reduce the complexity of providing backward compatibility.</t>
      <t>A BGP speaker that is capable of receiving BGP
    Extended Messages SHOULD advertise the BGP Extended Message
    Capability to its peers using BGP Capabilities Advertisement <xref target="RFC5492" format="default"/>.  A BGP speaker MAY send Extended Messages to a
    peer only if the Extended Message Capability was received from that
    peer.</t>
      <t>An implementation that advertises the BGP Extended Message
    capability MUST be capable of receiving a message with a Length up
    to and including 65,535 octets.</t>
      <t>Applications generating information which might be encapsulated
    within BGP messages MUST limit the size of their payload to take the
    maximum message size into account.</t>
      <t>During the years of incremental deployment, speakers that are
    capable of Extended Messages should not simply pack as many NLRI in
    a message as they can, or otherwise unnecessarily generate UPDATES
    above the 4,096 octet pre- Extended Message limit, so as not to
    require downstream routers to decompose for peers that do not
    support Extended Messages.  See <xref target="Security" format="default"/>.</t>
      <t>If a BGP message with a Length greater than 4,096 octets is
    received by a BGP listener who has not advertised the Extended
    Message Capability, the listener will generate a NOTIFICATION with
    the Error Subcode set to Bad Message Length (<xref target="RFC4271" format="default"/> Sec 6.1).</t>
      <t>A BGP UPDATE will (policy, best path, etc., allowing) typically
    propagate throughout the BGP speaking Internet; and hence to BGP
    speakers which may not support Extended Messages.  Therefore, an
    announcement in an Extended Message where the size of the attribute
    set plus the NLRI is larger than 4,096 octets may cause lack of
    reachability.</t>
      <t>A BGP speaker that has advertised the BGP Extended Message
    capability to its peers, may receive an UPDATE from one of its peers
    that produces an ongoing announcement that is larger than 4,096
    octets.  When propagating that UPDATE onward to a neighbor which has
    not advertised the BGP Extended Message capability, the speaker
    SHOULD try to reduce the outgoing message size by removing
    attributes eligible under the "attribute discard" approach of <xref target="RFC7606" format="default"/>.  If the message is still too big, then it must
    not be sent to the neighbor (<xref target="RFC4271" format="default"/>, Section 9.2).
    Additionally, if the NLRI was previously advertised to that peer, it
    must be withdrawn from service (<xref target="RFC4271" format="default"/>, Section
    9.1.3).</t>
      <t>If an Autonomous System (AS) has multiple internal BGP speakers
    and also has multiple external BGP neighbors, to present a
    consistent external view care must be taken to ensure a consistent
    view within the AS.  In the context of BGP Extended Messages, a
    consistent view can only be guaranteed if all the iBGP speakers
    advertise the BGP Extended Message capability.  If that is not the
    case, then the operator should consider whether the BGP Extended
    Message capability should be advertised to external peers or
    not.</t>
      <t>During the incremental deployment of BGP Extended Messages and
    <xref target="RFC7606" format="default"/> in an iBGP mesh, or with eBGP peers, the
    operator should monitor any routes dropped and any discarded
    attributes.</t>
    </section>
    <section anchor="error" numbered="true" toc="default">
      <name>Error Handling</name>
      <t>A BGP speaker that has the ability to use Extended Messages but
    has not advertised the BGP Extended Messages capability, presumably
    due to configuration, MUST NOT accept an Extended Message.  A
    speaker MUST NOT implement a more liberal policy accepting BGP
    Extended Messages.</t>
      <t>A BGP speaker that does not advertise the BGP Extended Messages
    capability might also genuinely not support Extended Messages.  Such
    a speaker will follow the error handling procedures of <xref target="RFC4271" format="default"/> if it receives an Extended Message.  Similarly,
    any speaker that treats an improper Extended Message as a fatal
    error, MUST follow the error handling procedures of <xref target="RFC4271" format="default"/>.</t>
      <t> The UPDATE Message Error Handling, as specified in Section 6.3
    of <xref target="RFC4271" format="default"/>, is unchanged.  However, if a
    NOTIFICATION is to be sent to a BGP speaker that has not advertised
    the BGP Extended Message Capability, the size of the message MUST
    NOT exceed 4,096 octets.</t>
      <t>It is RECOMMENDED that BGP protocol developers and implementers
    are conservative in their application and use of Extended Messages.
    Future protocol specifications MUST describe how to handle peers
    which can only accommodate 4,096 octet messages.</t>
    </section>
    <section anchor="rfc4171" numbered="true" toc="default">
      <name>Changes to RFC4271</name>
      <t><xref target="RFC4271" format="default"/> states "The value of the Length field
    MUST always be at least 19 and no greater than 4,096."  This document
    changes the latter number to 65,535 for all except the OPEN and
    KEEPALIVE messages.</t>
      <t><xref target="RFC4271" format="default"/> Sec 6.1, specifies raising an error if
    the length of a message is over 4,096 octets.  For all messages
    except the OPEN message, if the receiver has advertised the
    BGP Extended Messages Capability, this document raises that
    limit to 65,535.</t>
    </section>
    <section anchor="IANA" numbered="true" toc="default">
      <name>IANA Considerations</name>
      <t>The IANA has made an early allocation for this new BGP Extended
    Message Capability referring to this document.</t>
      <artwork name="" type="" align="left" alt=""><![CDATA[
Registry: Capability Codes

Value    Description                               Document 
-----    -----------------------------------       -------------
6        BGP Extended Message                      [this draft] 
        ]]></artwork>
    </section>
    <section anchor="Security" numbered="true" toc="default">
      <name>Security Considerations</name>
      <t>This extension to BGP does not change BGP's underlying security
    issues; <xref target="RFC4272" format="default"/>.</t>
      <t>Due to increased memory requirements for buffering, there may be
    increased exposure to resource exhaustion, intentional or
    unintentional.</t>
      <t>If a remote speaker is able to craft a large BGP Extended Message
    to send on a path where one or more peers do not support BGP
    Extended Messages, peers which support BGP Extended Messages may act
    to reduce the outgoing message, see <xref target="opns" format="default"/>, and in
    doing so cause an attack by discarding attributes its peer may be
    expecting.  The attributes eligible under the "attribute discard"
    must have no effect on route selection or installation <xref target="RFC7606" format="default"/>.</t>
      <t>If a remote speaker is able to craft a large BGP Extended
    Message to send on a path where one or more peers do not support BGP
    Extended Messages, peers which support BGP Extended Messages may act
    to reduce the outgoing message, see <xref target="opns" format="default"/>, and in
    doing so allow a downgrade attack.   This would only affect the
    attacker's message, where 'downgrade' has questionable meaning.</t>
      <t>If a remote speaker is able to craft a large BGP Extended
    Message to send on a path where one or more peers do not support BGP
    Extended Messages, peers which support BGP Extended Messages may
    incur resource load (processing, message resizing, etc.)
    reformatting the large messages.</t>
    </section>
    <section anchor="Acknowledgments" numbered="true" toc="default">
      <name>Acknowledgments</name>
      <t>The authors thank Alvaro Retana for an amazing review, Enke Chen,
    Susan Hares, John Scudder, John Levine, and Job Snijders for their
    input; and Oliver Borchert and Kyehwan Lee for their implementations
    and testing.</t>
    </section>
  </middle>
  <back>
    <references>
      <name>References</name>
      <references>
        <name>Normative References</name>
        <reference anchor="RFC2119" target="https://www.rfc-editor.org/info/rfc2119">
          <front>
            <title>Key words for use in RFCs to Indicate Requirement Levels</title>
            <seriesInfo name="DOI" value="10.17487/RFC2119"/>
            <seriesInfo name="RFC" value="2119"/>
            <seriesInfo name="BCP" value="14"/>
            <author initials="S." surname="Bradner" fullname="S. Bradner">
              <organization/>
            </author>
            <date year="1997" month="March"/>
            <abstract>
              <t>In many standards track documents several words are used to signify the requirements in the specification.  These words are often capitalized. This document defines these words as they should be interpreted in IETF documents.  This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
            </abstract>
          </front>
        </reference>
        <reference anchor="RFC4271" target="https://www.rfc-editor.org/info/rfc4271">
          <front>
            <title>A Border Gateway Protocol 4 (BGP-4)</title>
            <seriesInfo name="DOI" value="10.17487/RFC4271"/>
            <seriesInfo name="RFC" value="4271"/>
            <author initials="Y." surname="Rekhter" fullname="Y. Rekhter" role="editor">
              <organization/>
            </author>
            <author initials="T." surname="Li" fullname="T. Li" role="editor">
              <organization/>
            </author>
            <author initials="S." surname="Hares" fullname="S. Hares" role="editor">
              <organization/>
            </author>
            <date year="2006" month="January"/>
            <abstract>
              <t>This document discusses the Border Gateway Protocol (BGP), which is an inter-Autonomous System routing protocol.</t>
              <t>The primary function of a BGP speaking system is to exchange network reachability information with other BGP systems.  This network reachability information includes information on the list of Autonomous Systems (ASes) that reachability information traverses. This information is sufficient for constructing a graph of AS connectivity for this reachability from which routing loops may be pruned, and, at the AS level, some policy decisions may be enforced.</t>
              <t>BGP-4 provides a set of mechanisms for supporting Classless Inter-Domain Routing (CIDR).  These mechanisms include support for advertising a set of destinations as an IP prefix, and eliminating the concept of network "class" within BGP.  BGP-4 also introduces mechanisms that allow aggregation of routes, including aggregation of AS paths.</t>
              <t>This document obsoletes RFC 1771.  [STANDARDS-TRACK]</t>
            </abstract>
          </front>
        </reference>
        <reference anchor="RFC5492" target="https://www.rfc-editor.org/info/rfc5492">
          <front>
            <title>Capabilities Advertisement with BGP-4</title>
            <seriesInfo name="DOI" value="10.17487/RFC5492"/>
            <seriesInfo name="RFC" value="5492"/>
            <author initials="J." surname="Scudder" fullname="J. Scudder">
              <organization/>
            </author>
            <author initials="R." surname="Chandra" fullname="R. Chandra">
              <organization/>
            </author>
            <date year="2009" month="February"/>
            <abstract>
              <t>This document defines an Optional Parameter, called Capabilities, that is expected to facilitate the introduction of new capabilities in the Border Gateway Protocol (BGP) by providing graceful capability advertisement without requiring that BGP peering be terminated.</t>
              <t>This document obsoletes RFC 3392.  [STANDARDS-TRACK]</t>
            </abstract>
          </front>
        </reference>
        <reference anchor="RFC7606" target="https://www.rfc-editor.org/info/rfc7606">
          <front>
            <title>Revised Error Handling for BGP UPDATE Messages</title>
            <seriesInfo name="DOI" value="10.17487/RFC7606"/>
            <seriesInfo name="RFC" value="7606"/>
            <author initials="E." surname="Chen" fullname="E. Chen" role="editor">
              <organization/>
            </author>
            <author initials="J." surname="Scudder" fullname="J. Scudder" role="editor">
              <organization/>
            </author>
            <author initials="P." surname="Mohapatra" fullname="P. Mohapatra">
              <organization/>
            </author>
            <author initials="K." surname="Patel" fullname="K. Patel">
              <organization/>
            </author>
            <date year="2015" month="August"/>
            <abstract>
              <t>According to the base BGP specification, a BGP speaker that receives an UPDATE message containing a malformed attribute is required to reset the session over which the offending attribute was received. This behavior is undesirable because a session reset would impact not only routes with the offending attribute but also other valid routes exchanged over the session.  This document partially revises the error handling for UPDATE messages and provides guidelines for the authors of documents defining new attributes.  Finally, it revises the error handling procedures for a number of existing attributes.</t>
              <t>This document updates error handling for RFCs 1997, 4271, 4360, 4456, 4760, 5543, 5701, and 6368.</t>
            </abstract>
          </front>
        </reference>
        <reference anchor="RFC8174" target="https://www.rfc-editor.org/info/rfc8174">
          <front>
            <title>Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words</title>
            <seriesInfo name="DOI" value="10.17487/RFC8174"/>
            <seriesInfo name="RFC" value="8174"/>
            <seriesInfo name="BCP" value="14"/>
            <author initials="B." surname="Leiba" fullname="B. Leiba">
              <organization/>
            </author>
            <date year="2017" month="May"/>
            <abstract>
              <t>RFC 2119 specifies common key words that may be used in protocol  specifications.  This document aims to reduce the ambiguity by clarifying that only UPPERCASE usage of the key words have the  defined special meanings.</t>
            </abstract>
          </front>
        </reference>
      </references>
      <references>
        <name>Informative References</name>
        <reference anchor="RFC4272" target="https://www.rfc-editor.org/info/rfc4272">
          <front>
            <title>BGP Security Vulnerabilities Analysis</title>
            <seriesInfo name="DOI" value="10.17487/RFC4272"/>
            <seriesInfo name="RFC" value="4272"/>
            <author initials="S." surname="Murphy" fullname="S. Murphy">
              <organization/>
            </author>
            <date year="2006" month="January"/>
            <abstract>
              <t>Border Gateway Protocol 4 (BGP-4), along with a host of other infrastructure protocols designed before the Internet environment became perilous, was originally designed with little consideration for protection of the information it carries.  There are no mechanisms internal to BGP that protect against attacks that modify, delete, forge, or replay data, any of which has the potential to disrupt overall network routing behavior.</t>
              <t>This document discusses some of the security issues with BGP routing data dissemination.  This document does not discuss security issues with forwarding of packets.  This memo provides information for the Internet community.</t>
            </abstract>
          </front>
        </reference>
        <reference anchor="RFC7752" target="https://www.rfc-editor.org/info/rfc7752">
          <front>
            <title>North-Bound Distribution of Link-State and Traffic Engineering (TE) Information Using BGP</title>
            <seriesInfo name="DOI" value="10.17487/RFC7752"/>
            <seriesInfo name="RFC" value="7752"/>
            <author initials="H." surname="Gredler" fullname="H. Gredler" role="editor">
              <organization/>
            </author>
            <author initials="J." surname="Medved" fullname="J. Medved">
              <organization/>
            </author>
            <author initials="S." surname="Previdi" fullname="S. Previdi">
              <organization/>
            </author>
            <author initials="A." surname="Farrel" fullname="A. Farrel">
              <organization/>
            </author>
            <author initials="S." surname="Ray" fullname="S. Ray">
              <organization/>
            </author>
            <date year="2016" month="March"/>
            <abstract>
              <t>In a number of environments, a component external to a network is called upon to perform computations based on the network topology and current state of the connections within the network, including Traffic Engineering (TE) information.  This is information typically distributed by IGP routing protocols within the network.</t>
              <t>This document describes a mechanism by which link-state and TE information can be collected from networks and shared with external components using the BGP routing protocol.  This is achieved using a new BGP Network Layer Reachability Information (NLRI) encoding format.  The mechanism is applicable to physical and virtual IGP links.  The mechanism described is subject to policy control.</t>
              <t>Applications of this technique include Application-Layer Traffic Optimization (ALTO) servers and Path Computation Elements (PCEs).</t>
            </abstract>
          </front>
        </reference>
        <reference anchor="RFC8205" target="https://www.rfc-editor.org/info/rfc8205">
          <front>
            <title>BGPsec Protocol Specification</title>
            <seriesInfo name="DOI" value="10.17487/RFC8205"/>
            <seriesInfo name="RFC" value="8205"/>
            <author initials="M." surname="Lepinski" fullname="M. Lepinski" role="editor">
              <organization/>
            </author>
            <author initials="K." surname="Sriram" fullname="K. Sriram" role="editor">
              <organization/>
            </author>
            <date year="2017" month="September"/>
            <abstract>
              <t>This document describes BGPsec, an extension to the Border Gateway Protocol (BGP) that provides security for the path of Autonomous Systems (ASes) through which a BGP UPDATE message passes.  BGPsec is implemented via an optional non-transitive BGP path attribute that carries digital signatures produced by each AS that propagates the UPDATE message.  The digital signatures provide confidence that every AS on the path of ASes listed in the UPDATE message has explicitly authorized the advertisement of the route.</t>
            </abstract>
          </front>
        </reference>
      </references>
    </references>
  </back>
</rfc>
