<?xml version="1.0"?>
<!DOCTYPE rfc SYSTEM "rfc2629.dtd">
<?rfc comments="yes"?>
<?rfc compact="yes"?>
<?rfc inline="yes"?>
<?rfc sortrefs="yes"?>
<?rfc subcompact="yes"?>
<?rfc symrefs="yes"?>
<?rfc toc="yes"?>
<?rfc tocdepth="3"?>
<?rfc tocindent="yes"?>
<?rfc tocompact="yes"?>
<?rfc strict="yes"?>

<rfc category="std"
    docName="draft-ietf-idr-rfc8203bis-08"
    updates="4486"
    obsoletes="8203"
    ipr="trust200902">
    <front>
        <title abbrev="BGP Shutdown Communication">
            Extended BGP Administrative Shutdown Communication
        </title>

        <author fullname="Job Snijders" initials="J." surname="Snijders">
            <organization abbrev="NTT">NTT Communications</organization>
            <address>
                <postal>
                    <street>Theodorus Majofskistraat 100</street>
                    <code>1065 SZ</code>
                    <city>Amsterdam</city>
                    <country>The Netherlands</country>
                </postal>
                <email>job@ntt.net</email>
            </address>
        </author>

        <author fullname="Jakob Heitz" initials="J." surname="Heitz">
            <organization>Cisco</organization>
            <address>
                <postal>
                    <street>170 West Tasman Drive</street>
                    <city>San Jose</city>
                    <region>CA</region>
                    <code>95134</code>
                    <country>United States of America</country>
                </postal>
                <email>jheitz@cisco.com</email>
            </address>
        </author>

        <author fullname="John Scudder" initials="J." surname="Scudder">
            <organization abbrev="Juniper">Juniper Networks</organization>
            <address>
                <postal>
                    <street>1194 N. Mathilda Ave</street>
                    <city>Sunnyvale</city>
                    <region>CA</region>
                    <code>94089</code>
                    <country>United States of America</country>
                </postal>
                <email>jgs@juniper.net</email>
            </address>
        </author>

        <author fullname="Alexander Azimov" initials="A." surname="Azimov">
            <organization abbrev="Yandex">Yandex</organization>
            <address>
                <email>a.e.azimov@gmail.com</email>
            </address>
        </author>

        <date />

        <area>Routing</area>
        <workgroup>IDR</workgroup>
        <keyword>BGP</keyword>
        <keyword>cease</keyword>
        <keyword>shutdown</keyword>

        <abstract>
            <t>
                This document enhances the BGP Cease NOTIFICATION message "Administrative Shutdown" and "Administrative Reset" subcodes for operators to transmit a short freeform message to describe why a BGP session was shutdown or reset.
                This document updates RFC 4486 and obsoletes RFC 8203 by defining an Extended BGP Administrative Shutdown Communication of up to 255 octets to improve communication using multibyte character sets.
            </t>
        </abstract>

    <note title="Requirements Language">
        <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"/> <xref target="RFC8174"/> when,
            and only when, they appear in all capitals, as shown here.
        </t>
    </note>

    </front>

    <middle>
        <section anchor="intro" title="Introduction">
            <t>
                It can be troublesome for an operator to correlate a <xref target="RFC4271">BGP-4</xref> session teardown in the network with a notice that was transmitted via offline methods such as email or telephone calls.
                This document updates <xref target="RFC4486" /> by specifying a mechanism to transmit a short freeform <xref target="RFC3629">UTF-8</xref> message as part of a <xref target="RFC4271">Cease NOTIFICATION message</xref> to inform the peer why the BGP session is being shutdown or reset.
                This document obsoletes <xref target="RFC8203"/>; the
                specific differences and rationale are discussed in
                detail in <xref target="changes_to_8203"/>.
            </t>
        </section>

        <section anchor="message" title="Shutdown Communication">
            <t>
                If a BGP speaker decides to terminate its session with a BGP neighbor, and it sends a NOTIFICATION message with the Error Code "Cease" and Error Subcode "Administrative Shutdown" or "Administrative Reset" <xref target="RFC4486" />, it MAY include a UTF-8 encoded string.
                The contents of the string are at the operator's discretion.
            </t>
<t>
The Cease NOTIFICATION message with a Shutdown Communication is encoded as
below:
<figure anchor="encoding" align="center"><artwork><![CDATA[
 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Error Code 6  |    Subcode    |    Length     |     ...       \
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+               /
\                                                               \
/                 ... Shutdown Communication ...                /
\                                                               \
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
]]></artwork></figure>
</t>
            <t>
                <list style="hanging">
                    <t hangText="Subcode:">
                        the Error Subcode value MUST be one of the following
                        values: 2 ("Administrative Shutdown") or 4
                        ("Administrative Reset").
                    </t>
                    <t></t>
                    <t hangText="Length:">
                        this 8-bit field represents the length of the Shutdown
                        Communication field in octets.  When the length value is zero,
                        no Shutdown Communication field follows.
                    </t>
                    <t></t>
                    <t hangText="Shutdown Communication:">
                        to support international characters, the Shutdown
                        Communication field MUST be encoded using UTF-8. A
                        receiving BGP speaker MUST NOT interpret invalid UTF-8
                        sequences. Note that when the Shutdown Communication
                        contains multibyte characters, the number of characters
                        will be less than the length value. This field is not
                        NUL terminated. UTF-8 "Shortest Form" encoding is REQUIRED to guard against the technical issues outlined in <xref target="UTR36" />.
                    </t>
                </list>
            </t>
            <t>
                Mechanisms concerning the reporting of information contained in
                the Shutdown Communication are implementation specific but
                SHOULD include methods such as <xref target="RFC5424">Syslog</xref>.
            </t>
        </section>

        <section anchor="ops" title="Operational Considerations">
            <t>
                Operators are encouraged to use the Shutdown Communication to
                inform their peers of the reason for the shutdown of the BGP
                session and include out-of-band reference materials.  An
                example of a useful Shutdown Communication would be:
            </t>
            <t>"[TICKET-1-1438367390] software upgrade; back in 2 hours"</t>
            <t>
                "[TICKET-1-1438367390]" is a ticket reference with significance to both the sender and receiver, followed by a brief human-readable message regarding the reason for the BGP session shutdown followed by an indication about the length of the maintenance.
                The receiver can now use the string 'TICKET-1-1438367390' to search in their email archive to find more details.
            </t>
            <t>
   If a Shutdown Communication longer than 128 octets is sent to a BGP
   speaker that implements [RFC8203], then that speaker will treat it as
   an error, the consequence of which should be a log message.
            </t>
            <t>
   If a Shutdown Communication of any length is sent to a BGP
   speaker that implements neither [RFC8203] nor this specification,
   then that speaker will treat it as
   an error, the consequence of which should be a log message.
            </t>
            <t>
   In any case, a receiver of a NOTIFICATION message is unable to
   acknowledge the receipt and correct understanding of any
   Shutdown Communication.
            </t>
            <t>
   Operators should not rely on Shutdown Communications as their
   sole form of communication with their peer for important events.
            </t>
            <t>
   If it is known that the peer BGP speaker supports this specification,
   then a Shutdown Communication that is not longer than 255 octets MAY be sent.
   Otherwise, a Shutdown Communication MAY be sent, but it SHOULD NOT be
   longer than 128 octets.
            </t>
        </section>

        <section anchor="error" title="Error Handling">
            <t>
			   If a Shutdown Communication with an invalid UTF-8
			   sequence is received, a message indicating this event
			   SHOULD be logged for the attention of the operator.  An
			   erroneous or malformed Shutdown Communication itself MAY
			   be logged in a hexdump format.
            </t>
        </section>

        <section anchor="iana" title="IANA Considerations">
            <t>
                IANA is requested to reference this document at subcode "Administrative Shutdown", and at subcode "Administrative Reset" in the "BGP Cease NOTIFICATION message subcodes" registry under the "Border Gateway Protocol (BGP) Parameters" group in addition to <xref target="RFC4486" />.
            </t>
        </section>

        <section anchor="security" title="Security Considerations">
            <t>
                This document uses UTF-8 encoding for the Shutdown Communication.
                There are a number of security issues with Unicode.
                Implementers and operators are advised to review <xref target="UTR36">Unicode Technical Report #36</xref> to learn about these issues.
                UTF-8 "Shortest Form" encoding is REQUIRED to guard against the technical issues outlined in <xref target="UTR36" />.
            </t>
            <t>
                As BGP Shutdown Communications are likely to appear in syslog output, there is a risk that carefully constructed Shutdown Communication might be formatted by receiving systems in a way to make them appear as additional syslog messages.
                The 255 octet length limit on the BGP Shutdown
                Communication may help limit the ability to mount such
                an attack.
            </t>
            <t>
                Users of this mechanism should be aware that unless a transport that provides integrity is used for the BGP session in question, a Shutdown Communication message could be forged.
                Unless a transport that provides confidentiality is used, a Shutdown Communication message could be snooped by an attacker.
                These issues are common to any BGP message but may be of greater interest in the context of this proposal since the information carried in the message is generally expected to be used for human-to-human communication.
                Refer to the related considerations in <xref target="RFC4271" /> and <xref target="RFC4272" />.
            </t> 
            <t>
                Users of this mechanism should consider applying data minimization practices as outlined in <xref target="RFC6973">Section 6.1 of</xref> because a received Shutdown Communication may be used at the receiver's discretion.
            </t>
        </section>
 
    </middle>

    <back>

        <references title="Normative References">
            <?rfc include="reference.RFC.2119"?>
            <?rfc include="reference.RFC.8174"?>
            <?rfc include="reference.RFC.3629"?>
            <?rfc include="reference.RFC.4271"?>
            <?rfc include="reference.RFC.4486"?>
        </references>
        <references title="Informative References">
            <?rfc include="reference.RFC.4272"?>
            <?rfc include="reference.RFC.5424"?>
            <?rfc include="reference.RFC.6973"?>
            <?rfc include="reference.RFC.8203"?>
            <reference anchor="UTR36" target="http://unicode.org/reports/tr36/">
                <front>
                    <title>Unicode Security Considerations</title>
                    <author initials="M." surname="Davis" fullname="Mark Davis"><organization/></author>
                    <author initials="M." surname="Suignard" fullname="Michel Suignard"><organization/></author>
                    <date year="2010" month="August" day="4"/>
                </front>
                <seriesInfo name="Unicode Technical Report" value="#36"/>
            </reference>
        </references>

        <section anchor="acknowledgements" title="Acknowledgements">
            <t>
                The authors would like to gratefully acknowledge Tom Scholl, David Freedman, Jared Mauch, Jeff Haas, Peter Hessler, Bruno Decraene, John Heasley, Peter van Dijk, Arjen Zonneveld, James Bensley, Susan Hares, Saku Ytti, Lou Berger, Alvaro Retana, and Adam Roach.
            </t>
            <t>
                The authors would like to thank Enke Chen and Vincent Gillet for their work on <xref target="RFC4486"/> and granting the related BCP 78 rights to the IETF Trust.
            </t>
            <t>
                The authors would like to acknowledge Misha Grishin (MSK-IX) for raising awareness that <xref target="RFC8203"/>'s length specification was insufficient in context of multibyte character sets.
            </t>
        </section>

	    <section anchor="changes_to_8203" title="Changes to RFC 8203">
			<t>
			The maximum permitted length was changed from 128 to 255.
            </t>
            <t>
				Feedback from operators based in regions which predominantly use multibyte character sets, showed that messages similar in meaning to what can be send in other languages in using single-byte encoding, failed to fit within the Length constraints as specified by <xref target="RFC8203"/>.
				For example, the phrase: 'Planned work to add switch to stack.  Completion time - 30 minutes' has length 65 bytes.
				Its translation in Russian has length 139 bytes.
            </t>
            <t>
			If a Shutdown Communication message longer than 128 octets is sent to a BGP speaker that implements <xref target="RFC8203"/>, then that speaker will bring it to the attention of an operator, but will otherwise process the NOTIFICATION message as normal.
			</t>
    </section>
    </back>
</rfc>
