diff options
author | Tibor Frank <tifrank@cisco.com> | 2019-11-14 10:06:03 +0100 |
---|---|---|
committer | Tibor Frank <tifrank@cisco.com> | 2019-11-21 14:05:37 +0100 |
commit | 497f606967363d88b4b36b74859ad360eba9eccd (patch) | |
tree | 38da8ab880400168509c2e5cfb4604b9ea1e53f3 /resources/libraries/python/SFC/TunnelProtocol.py | |
parent | e7ad66f3147662973039caaac33015de7e0c6f8c (diff) |
NSH_SFC: Remove
Change-Id: Ib7f9dff7bede4f8ec3148f234109132be920de82
Signed-off-by: Tibor Frank <tifrank@cisco.com>
Diffstat (limited to 'resources/libraries/python/SFC/TunnelProtocol.py')
-rw-r--r-- | resources/libraries/python/SFC/TunnelProtocol.py | 43 |
1 files changed, 0 insertions, 43 deletions
diff --git a/resources/libraries/python/SFC/TunnelProtocol.py b/resources/libraries/python/SFC/TunnelProtocol.py deleted file mode 100644 index 3248cf9103..0000000000 --- a/resources/libraries/python/SFC/TunnelProtocol.py +++ /dev/null @@ -1,43 +0,0 @@ -# Copyright (c) 2017 Cisco and/or its affiliates. -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at: -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -""" -This module implements the VxLAN/VXLAN-GPE/NSH protocol -for the packet analyse. -""" -from scapy.all import Packet -from scapy.all import XByteField, ShortField -from scapy.all import BitField, XBitField, IntField - -class VxLAN(Packet): - """Define the vxlan protocol for the packet analysis.""" - name = "vxlan" - fields_desc = [XByteField("flags", 0x08), BitField("reserved", 0, 24), - BitField("vni", 0, 24), XByteField("reserved", 0x00)] - -class VxLANGPE(Packet): - """Define the vxlan-gpe protocol for the packet analysis.""" - name = "vxlan-gpe" - fields_desc = [XByteField("flags", 0x0c), ShortField("reserved", 0), - XByteField("nextproto", 0x3), BitField("vni", 0, 24), - XByteField("reserved", 0x0)] - -class NSH(Packet): - """Define the NSH protocol for the packet analysis.""" - name = "nsh" - fields_desc = [XBitField("Version", 0x0, 2), XBitField("OAM", 0x0, 1), - XBitField("Unassigned", 0x0, 1), XBitField("TTL", 0x0, 6), - XBitField("length", 0x6, 6), XBitField("Unassigned", 0x0, 4), - XBitField("MDtype", 0x1, 4), XByteField("nextproto", 0x3), - IntField("nsp_nsi", 0), IntField("c1", 0), - IntField("c2", 0), IntField("c3", 0), IntField("c4", 0)] |