<?xml version="1.0" encoding="US-ASCII"?>
<!DOCTYPE rfc SYSTEM "rfc2629.dtd">
<?rfc toc="yes"?>
<?rfc tocompact="yes"?>
<?rfc tocdepth="3"?>
<?rfc tocindent="yes"?>
<?rfc symrefs="yes"?>
<?rfc sortrefs="yes"?>
<?rfc comments="yes"?>
<?rfc inline="yes"?>
<?rfc compact="yes"?>
<?rfc subcompact="no"?>

<rfc category='std' ipr='trust200902' docName='draft-ali-spring-sr-service-programming-oam-02'>

<front>
<title abbrev="SR-SP OAM">OAM for Service Programming with Segment Routing</title>

<author initials="Z." surname="Ali" fullname="Zafar Ali">
	<organization>Cisco Systems, Inc.</organization>
	<address>
		<postal>
		<street></street>
		<city></city> <region></region> <code></code>
		<country>US</country>
		</postal>
	<email>zali@cisco.com</email>
	</address>
</author>

<author initials="C." surname="Filsfils" fullname="Clarence Filsfils">
	<organization>Cisco Systems, Inc.</organization>
	<address>
		<postal>
		<street></street>
		<city></city> <region></region> <code></code>
		<country>Belgium</country>
		</postal>
	<email>cfilsfils@cisco.com</email>
	</address>
</author>

<author initials="N." surname="Nainar" fullname="Nagendra Kumar Nainar">
	<organization>Cisco Systems, Inc.</organization>
	<address>
		<postal>
		<street>7200-12 Kit Creek Road</street>
		<city>Research Triangle Park</city> <region>NC</region> <code>27709</code>
		<country>US</country>
		</postal>
	<email>naikumar@cisco.com</email>
	</address>
</author>

<author initials="C." surname="Pignataro" fullname="Carlos Pignataro">
	<organization>Cisco Systems, Inc.</organization>
	<address>
		<postal>
		<street>7200 Kit Creek Road</street>
		<city>Research Triangle Park</city> <region>NC</region> <code>27709-4987</code>
		<country>US</country>
		</postal>
	<email>cpignata@cisco.com</email>
	</address>
</author>

<author initials="F." surname="Clad" fullname="Francois Clad">
	<organization>Cisco Systems, Inc.</organization>
	<address>
		<postal>
		<street></street>
		<city></city> <region></region> <code></code>
		<country>France</country>
		</postal>
	<email>fclad@cisco.com</email>
	</address>
</author>

<author initials="F." surname="Iqbal" fullname="Faisal Iqbal">
	<organization>Cisco Systems, Inc.</organization>
	<address>
		<postal>
		<street>2000 Innovation Dr</street>
		<city>Ottawa</city> <region>ON</region> <code>3E8</code>
		<country>Canada</country>
		</postal>
	<email>faiqbal@cisco.com</email>
	</address>
</author>

<author initials="X." surname="Xu" fullname="Xiaohu Xu">
	<organization>Alibaba</organization>
	<address>
		<postal>
		<street></street>
		<city></city> <region></region> <code></code>
		<country></country>
		</postal>
	<email>xiaohu.xxh@alibaba-inc.com</email>
	</address>
</author>

    
<date/>
<area>Internet</area>
<workgroup>spring</workgroup>

<keyword>spring</keyword>

<abstract><t>
This document defines the Operations, Administrations and Maintenance (OAM) for service programming in SR-enabled MPLS and IP networks.
</t>
</abstract>

</front>

<middle>
	
	<section title="Introduction">
		<t>
		</t>
		<t><xref target="I-D.ietf-spring-sr-service-programming" /> defines data plane
   functionality required to implement service segments and achieve service
   programming in SR-enabled MPLS and IP networks, as described in the
   Segment Routing architecture. This document defines the Operations,
   Administrations and Maintenance (OAM) for service programming in
   SR-enabled MPLS and IP networks.
		</t>				
					
	</section>
	 
    <section title="Requirements notation">
					<t>
					The key words "MUST", "MUST NOT", "REQUIRED", "SHALL",
					"SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY",
					and "OPTIONAL" in this document are to be interpreted as
					described in <xref target="RFC2119"/>.
					</t>
    </section>
    
    <section title="Terminology">
    	<t>This document uses the terminologies defined in <xref target="RFC8402" />, <xref target="I-D.filsfils-spring-srv6-network-programming" />
    	<xref target="I-D.ietf-spring-sr-service-programming" />
    	and so the readers are expected to be familiar with the same.
    	</t>
    </section>
    
    <section title="Document Scope">
    	<t>The initial focus of this document to define and document the machinery required to apply OAM mechanisms on SRv6 based service programming.
    	</t>
    	<t>Future version of this document will include the required details to apply OAM mechanism on other data planes.
    	</t>
    </section>
    
    <section title="Programmable OAM">
    	<t>Section 4 of <xref target="I-D.ietf-spring-sr-service-programming" /> 
    	introduces Service segments and the procedure of service programming when the 
    	services are SR-aware and SR-unaware. By integrating the OAM functionality in the 
    	services, versatile OAM tool kits can be used to execute programmable OAM for 
    	service programming with Segment Routing.
    	</t>
    	
    	<t>This section describes the procedure to perform basic OAM mechanisms such as 
    	path validation and path tracing of Service Programming environment in Segment 
    	Routing network.
    	</t>
    	
    	<section title="Service Programming OAM Packet Marker">
    		<t>Any services upon receiving OAM packet may apply the service treatment if 
    		it cannot differentiate the OAM packet from normal data packet. Depending on 
    		the service type, service treatment on OAM packet may result in dropping the 
    		OAM probe packet that may cause uncertainty in OAM mechanism. 
    		</t>
    		
    		<t>To avoid such uncertainty, any node that is originating the OAM probe for 
    		Service Programming OAM MUST mark the packet as OAM packet so that the 
    		services can differentiate the OAM packet from data traffic.
    		</t>
    	</section>
    	
    	<section title="OAM with SR-aware services">
    		<t>As defined in section 4.1 of 
    		<xref target="I-D.ietf-spring-sr-service-programming" />, an SR-aware 
    		service can process the SR information in the packet header such as performing 
    		lookup or executing the next segment etc. An SR-aware 
    		service may need to identify the packet payload and/or interpret SR 
    		information to apply the right policy to the received packet. While processing 
    		SR information in the packet header,  it can process the OAM packet marker in 
    		the SR header to differentiate the OAM packet from normal data packet. 
    		</t>
    		
    		<t>An SR-aware service SHOULD skip applying the service on the OAM packet 
    		while forwarding the packet to the next segment or IP address. As 
    		defined in section 9, a local policy may be used to control any malicious use 
    		of OAM marker.
    		</t>
    	</section>
    	
    	<section title="OAM with SR-unaware services">
    		<t>As defined in section 4.2 of 
    		<xref target="I-D.ietf-spring-sr-service-programming" />, an SR-unaware 
    		service may be a legacy service that is not able to process the SR information 
    		in the packet header. SR Proxy, an entity that is external to the service is 
    		used to handle the SR information processing on behalf of the service. SR 
    		Proxy will remove the SR header before forwarding the packet to SR-unaware 
    		services to avoid any erroneous decision due to the presence of SR header 
    		that the service cannot recognize.
    		</t>
    		
    		<t>While processing SR information in the packet header,  SR proxy can process 
    		the OAM packet marker in the SR header to differentiate the OAM packet from 
    		normal data packet. SR Proxy MUST skip forwarding the packets with OAM marker 
    		to the service while forwarding the packet to the next segment or IP address. 
    		As defined in section 9, a local policy may be used to control 
    		any malicious use of OAM marker.
    		</t>
    	</section>
    	
    	<section title="Controlling OAM packet processing in Services">
    		<t>As mentioned in the above sections, SR-aware service or the SR proxy can 
    		use the OAM marker to differentiate the OAM packet from data packet to skip 
    		the 
    		service treatment. Any intentional or unintentional use of OAM marker in data 
    		traffic may result in skipping service treatment for data traffic. To avoid 
    		such condition, a local policy will be used in the SR-aware service or SR 
    		Proxy  that SHOULD rate limit or MAY drop the packets received with OAM 
    		marker.
    		</t>
    	</section>
    	
    </section>
    
    <section title="OAM for Service Programming with SRv6">
    	<t> <xref target="I-D.ietf-6man-segment-routing-header" /> defines 
    	SRH.Flags.O-bit in SRH header. When service programming is implemented with SRv6 
    	dataplane, SRH.Flags.O-bit  is used as OAM marker. An IPv6 packet received with a local END.OP or END.OTP SID is also considered as an OAM packet.
    	</t>
    	
    	<t>Any node that is originating OAM probe to a service in SRv6 dataplane MUST set 
    	SRH.Flags.O-bit in the SRH.
    	</t>
    	
    	<section title="OAM Tool Kit">
    		<t>This section describes the availability of different tool kits that can be 
    		used to perform OAM functionality for Service Programming with SRv6 dataplane.
    		</t>
    		
    		<section title="OAM Flag Processing">
    			<t>An SR-aware service or SR proxy MUST implement the SRH.Flags.O bit. 
    			An SR-aware service SHOULD skip applying the service to the packet when 
    			SRH.Flags.O-bit is set and SHOULD forward the packet based on the next 
    			header. SR Service Proxy MUST skip applying the service to the packet when 
    			SRH.Flags.O-bit is set and SHOULD forward the packet based on the next 
    			header.
    			</t>
    			
    			<t>An SR-aware service and SR proxy may choose to time-stamp and punt the 
    			packet with SRH.Flags.O-bit set for further processing and this is a local
    			implementation matter.
    			</t>
    		</section>
    		
    		<section title="OAM Segment ID">
    			<t>Section 3.2 of [<xref target="I-D.ali-spring-srv6-oam" />] defines OAM 
    			segment ID and the associated forwarding semantics to implement the punt 
    			behavior for OAM packets. Specifically, the draft defines END.OP and 
    			END.OTP SIDs. An IPv6 packet received with DA set to a local END.OP or 
    			END.OTP SID is considered as an OAM packet.
    			</t>
    			
    			<t>Any service policy head end MAY include OAM segment ID in the desired
    			segment list position of SRH.  The inclusion of OAM SID in SRH can be used 
    			to control the services that are required to punt the OAM packet for 
    			processing.
    			</t>
    		</section>
    		
    		<section title="ICMP">
    			<t>There is no hardware or software changes required to use ICMP for Ping 
    			operation. It can be triggered from the service policy head end or from 
    			any classical IPv6 nodes by sending ICMPv6 Echo Request. The existing ICMP 
    			Ping mechanism works seamlessly in SRv6 dataplane with no protocol changes 
    			required to the standard ICMPv6 [<xref target="RFC4443" />], 
    			[<xref target="RFC4884" />] or the standard ICMPv4 
    			[<xref target="RFC0792" />].
    			</t>
    			
    			<t>An SR-aware service SHOULD skip the service and forward to next segment 
    			based on the SR information in the packet header. An SR Service Proxy MUST skip the service and forward to next segment based on the SR information in the packet header.
    			</t>
    			
    			<section title="Pinging Service SID Function">
    			<t>When a remote node pings a service segment, it MUST set SRH.Flags.O = 1.
   If the target service segment is implemented with USP behavior, the ICMP
   packet can be constructed without adding END.OP or END.OTP SIDs defined
   in <xref target="I-D.ali-spring-srv6-oam" />. However, if the target service SID
   observes a PSP behavior, the sender needs to insert END.OP/ END.OTP SIDs
   before the target service SID in the segment-list. In either case, the
   target SR-aware service or SR proxy receives the ICMP echo request with
   either SRH.Flags.O-bit set or with the local END.OP or END.OTP SID.
   In both cases, the packet is punted for slow-path processing and service is
   skipped.
    			</t>
    			
    			<t>The Egress node process the packet as per procedure defined in
   <xref target="I-D.ali-spring-srv6-oam" />. The Egress checks if the target SID is
   locally programmed or not.
    			</t>
    			
    			<t>If the target SID is not locally programmed, the Egress responses with
   the ICMPv6 message (Type: "SRv6 OAM (TBA)", Code: "SID not
   locally implemented (TBA)"); otherwise a success is returned
   <xref target="I-D.ali-spring-srv6-oam" />.
    			</t>
    			</section>
    			
    		</section>
    		
    		<section title="UDP Probes">
    			<t>A classic traceroute mechanism relies on UDP probes by sending packets 
    			with sequentially incrementing the TTL. More details are available in 
    			section 4.3.1 of <xref target="I-D.ali-spring-srv6-oam" />.
    			</t>
    			
    			<t>An SR-aware service or SR proxy  upon receiving the probe with TTL=1, 
    			may follow the traditional behavior of replying with ICMPv6 Time Exceeded 
    			Message (Type 3) as defined in <xref target="RFC4443" /> without applying the service.
    			</t>
    			
    			<t>Use of SRH.Flags.O bit and END.OP/ END.OTP SIDs as OAM marker in the UDP
   probe for trace route is same as discussed for ICMPv6 ping discussed in
   the last section.
    			</t>
    		</section>
    		
    		<section title="In-band OAM">
    			<t>To be Updated.
    			</t>
    		</section>
    		
    	</section>
    </section>
    
    <section title="OAM for Service Programming with SR-MPLS">
    	<t>To be updated.
    	</t>
    </section>
    
		<section title="IANA Considerations">
		<t>None.</t>
		</section>
        <section title="Security Considerations">
		<t>A local policy may be used to control any malicious use of OAM marker.
   More details are to be added in a future revision of the document.</t>
		</section>
		<section title="Acknowledgement">
					<t>Authors would like to thank Bruno Decraene for his review and 
					useful comments.</t>
		</section>
    </middle>
	
<back>

    <references title="Normative References">
	
	<?rfc include="reference.RFC.2119"?>
	
	<?rfc include="reference.RFC.7665"?>
	
	<?rfc include="reference.RFC.4443"?>
	
	<?rfc include="reference.RFC.4884"?>
	
	<?rfc include="reference.RFC.0792"?>
	
	<?rfc include="reference.I-D.ali-spring-srv6-oam"?>
	
	<?rfc include="reference.RFC.8402"?>
	
	<?rfc include="reference.I-D.filsfils-spring-srv6-network-programming"?>
	
	<?rfc include="reference.I-D.ietf-6man-segment-routing-header"?>
	
	<?rfc include="reference.I-D.ietf-spring-sr-service-programming"?>
	  
    </references>
    


		</back>

</rfc>
