Top Banner
MUM EUROPE 2017
84

MUM Europe 2017 - Traffic Generator Case Study

Apr 10, 2017

Download

Technology

Fajar Nugroho
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: MUM Europe 2017 - Traffic Generator Case Study

MUM EUROPE

2017

MIKROTIK TRAFFIC GENERATOR STUDY

CASE

JOSE MANUEL ROMANj o s e r o m a n f i b e r c l i c o m + 3 4 6 5 2 2 4 1 4 3 1

M A D R I D P R A G U E

bull (2016 ndashNow) CEO FiberCLI

bull (2015 ndashNow) CTO WISP

17 years experience at IT industry Mikrotik Certified Consultant and Trainer MTCNA MTCRE MTCTCE

MTCUME MTCWE MTCIPv6E MTCINE CISACISSP Master ITIL

bull (2008 ndashNow) Security Consultant and Analyst

bull (2000 ndash2007) Networking Security and ITIL Teacher

JOSE MANUEL ROMANJ O S E r o m a n f i b e r c l i c o m + 3 4 6 5 2 2 4 1 4 3 1

M A D R I D P R A G U E

bull (2016 MUM Middle East) -System integration and analysis

bull (2016 MUM Spain) - Integracioacuten de MikroTik con cabeceras de fibra oacuteptica

bull (2016 MUM Europe) -Securing and testing with MikroTik

bull (2015 MUM Spain) -Pruebas de seguridad y configuracioacuten con Mikrotik

My previous presentations at MUM

COMPANY PROFILE

PROJECT BASEDbull Fiber optic installation outdor and

indoor (Hotel and Office Building)

bull Wireless installation Rural area and

City

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

CONSULTANTbull Mikrotik Products

bull Licensed Antennas

bull Ipv4 Brocker

bull Advanced monitoring integrations

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

TRAININGbull Official Mikrotik Training Partner

with three different languages and

modules (English Indonesia and

Spanish)

bull Courses on premises of companies in

Europe and middle east

bull Specialized in IPv6

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

AGENDA

Traffic Generator Introduction Special Use Case Example

Objetive

The goal of this presentation is to explain the operation of the traffic generator

11

Problem

What to do when I need to test or audit whether a router or a system is working correctly

12

Symptoms

We have a complex configuration and we have no idea how to test it

13

Solution

Traffic generator

14

TRAFFIC GENERATORINTRODUCTION

WHAT IS TRAFFIC

GENERATOR

Traffic Generator is a tool that allows to evaluate performance of DUT (Device Under Test) or SUT (System Under Test)

ldquoldquohttpswikimikrotikcomwikiManualToolsTraffic_Generator

WHATrsquoS TRAFFIC GENERATOR CAN

DO

ldquo

ldquo

Traffic Generator tool can generate and send RAW packets over specific ports It also collects latency and jitter values txrx rates counts lost packets and

detects Out-of-Order (OOO) packets

Traffic Generator can be used similar to bandwidth test tool as well as generate packets that will be routed back to packet generator for advanced

status collection

DEVICE UNDER TEST

TRAFFIC GENERATOR

Test performance of device or system before migrate to production

infrastructure such as

bull PPS (Packet Per Second)

bull Throughput Bandwidth

bull CPU

bull Hardware Encryption

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 2: MUM Europe 2017 - Traffic Generator Case Study

MIKROTIK TRAFFIC GENERATOR STUDY

CASE

JOSE MANUEL ROMANj o s e r o m a n f i b e r c l i c o m + 3 4 6 5 2 2 4 1 4 3 1

M A D R I D P R A G U E

bull (2016 ndashNow) CEO FiberCLI

bull (2015 ndashNow) CTO WISP

17 years experience at IT industry Mikrotik Certified Consultant and Trainer MTCNA MTCRE MTCTCE

MTCUME MTCWE MTCIPv6E MTCINE CISACISSP Master ITIL

bull (2008 ndashNow) Security Consultant and Analyst

bull (2000 ndash2007) Networking Security and ITIL Teacher

JOSE MANUEL ROMANJ O S E r o m a n f i b e r c l i c o m + 3 4 6 5 2 2 4 1 4 3 1

M A D R I D P R A G U E

bull (2016 MUM Middle East) -System integration and analysis

bull (2016 MUM Spain) - Integracioacuten de MikroTik con cabeceras de fibra oacuteptica

bull (2016 MUM Europe) -Securing and testing with MikroTik

bull (2015 MUM Spain) -Pruebas de seguridad y configuracioacuten con Mikrotik

My previous presentations at MUM

COMPANY PROFILE

PROJECT BASEDbull Fiber optic installation outdor and

indoor (Hotel and Office Building)

bull Wireless installation Rural area and

City

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

CONSULTANTbull Mikrotik Products

bull Licensed Antennas

bull Ipv4 Brocker

bull Advanced monitoring integrations

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

TRAININGbull Official Mikrotik Training Partner

with three different languages and

modules (English Indonesia and

Spanish)

bull Courses on premises of companies in

Europe and middle east

bull Specialized in IPv6

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

AGENDA

Traffic Generator Introduction Special Use Case Example

Objetive

The goal of this presentation is to explain the operation of the traffic generator

11

Problem

What to do when I need to test or audit whether a router or a system is working correctly

12

Symptoms

We have a complex configuration and we have no idea how to test it

13

Solution

Traffic generator

14

TRAFFIC GENERATORINTRODUCTION

WHAT IS TRAFFIC

GENERATOR

Traffic Generator is a tool that allows to evaluate performance of DUT (Device Under Test) or SUT (System Under Test)

ldquoldquohttpswikimikrotikcomwikiManualToolsTraffic_Generator

WHATrsquoS TRAFFIC GENERATOR CAN

DO

ldquo

ldquo

Traffic Generator tool can generate and send RAW packets over specific ports It also collects latency and jitter values txrx rates counts lost packets and

detects Out-of-Order (OOO) packets

Traffic Generator can be used similar to bandwidth test tool as well as generate packets that will be routed back to packet generator for advanced

status collection

DEVICE UNDER TEST

TRAFFIC GENERATOR

Test performance of device or system before migrate to production

infrastructure such as

bull PPS (Packet Per Second)

bull Throughput Bandwidth

bull CPU

bull Hardware Encryption

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 3: MUM Europe 2017 - Traffic Generator Case Study

JOSE MANUEL ROMANj o s e r o m a n f i b e r c l i c o m + 3 4 6 5 2 2 4 1 4 3 1

M A D R I D P R A G U E

bull (2016 ndashNow) CEO FiberCLI

bull (2015 ndashNow) CTO WISP

17 years experience at IT industry Mikrotik Certified Consultant and Trainer MTCNA MTCRE MTCTCE

MTCUME MTCWE MTCIPv6E MTCINE CISACISSP Master ITIL

bull (2008 ndashNow) Security Consultant and Analyst

bull (2000 ndash2007) Networking Security and ITIL Teacher

JOSE MANUEL ROMANJ O S E r o m a n f i b e r c l i c o m + 3 4 6 5 2 2 4 1 4 3 1

M A D R I D P R A G U E

bull (2016 MUM Middle East) -System integration and analysis

bull (2016 MUM Spain) - Integracioacuten de MikroTik con cabeceras de fibra oacuteptica

bull (2016 MUM Europe) -Securing and testing with MikroTik

bull (2015 MUM Spain) -Pruebas de seguridad y configuracioacuten con Mikrotik

My previous presentations at MUM

COMPANY PROFILE

PROJECT BASEDbull Fiber optic installation outdor and

indoor (Hotel and Office Building)

bull Wireless installation Rural area and

City

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

CONSULTANTbull Mikrotik Products

bull Licensed Antennas

bull Ipv4 Brocker

bull Advanced monitoring integrations

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

TRAININGbull Official Mikrotik Training Partner

with three different languages and

modules (English Indonesia and

Spanish)

bull Courses on premises of companies in

Europe and middle east

bull Specialized in IPv6

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

AGENDA

Traffic Generator Introduction Special Use Case Example

Objetive

The goal of this presentation is to explain the operation of the traffic generator

11

Problem

What to do when I need to test or audit whether a router or a system is working correctly

12

Symptoms

We have a complex configuration and we have no idea how to test it

13

Solution

Traffic generator

14

TRAFFIC GENERATORINTRODUCTION

WHAT IS TRAFFIC

GENERATOR

Traffic Generator is a tool that allows to evaluate performance of DUT (Device Under Test) or SUT (System Under Test)

ldquoldquohttpswikimikrotikcomwikiManualToolsTraffic_Generator

WHATrsquoS TRAFFIC GENERATOR CAN

DO

ldquo

ldquo

Traffic Generator tool can generate and send RAW packets over specific ports It also collects latency and jitter values txrx rates counts lost packets and

detects Out-of-Order (OOO) packets

Traffic Generator can be used similar to bandwidth test tool as well as generate packets that will be routed back to packet generator for advanced

status collection

DEVICE UNDER TEST

TRAFFIC GENERATOR

Test performance of device or system before migrate to production

infrastructure such as

bull PPS (Packet Per Second)

bull Throughput Bandwidth

bull CPU

bull Hardware Encryption

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 4: MUM Europe 2017 - Traffic Generator Case Study

JOSE MANUEL ROMANJ O S E r o m a n f i b e r c l i c o m + 3 4 6 5 2 2 4 1 4 3 1

M A D R I D P R A G U E

bull (2016 MUM Middle East) -System integration and analysis

bull (2016 MUM Spain) - Integracioacuten de MikroTik con cabeceras de fibra oacuteptica

bull (2016 MUM Europe) -Securing and testing with MikroTik

bull (2015 MUM Spain) -Pruebas de seguridad y configuracioacuten con Mikrotik

My previous presentations at MUM

COMPANY PROFILE

PROJECT BASEDbull Fiber optic installation outdor and

indoor (Hotel and Office Building)

bull Wireless installation Rural area and

City

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

CONSULTANTbull Mikrotik Products

bull Licensed Antennas

bull Ipv4 Brocker

bull Advanced monitoring integrations

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

TRAININGbull Official Mikrotik Training Partner

with three different languages and

modules (English Indonesia and

Spanish)

bull Courses on premises of companies in

Europe and middle east

bull Specialized in IPv6

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

AGENDA

Traffic Generator Introduction Special Use Case Example

Objetive

The goal of this presentation is to explain the operation of the traffic generator

11

Problem

What to do when I need to test or audit whether a router or a system is working correctly

12

Symptoms

We have a complex configuration and we have no idea how to test it

13

Solution

Traffic generator

14

TRAFFIC GENERATORINTRODUCTION

WHAT IS TRAFFIC

GENERATOR

Traffic Generator is a tool that allows to evaluate performance of DUT (Device Under Test) or SUT (System Under Test)

ldquoldquohttpswikimikrotikcomwikiManualToolsTraffic_Generator

WHATrsquoS TRAFFIC GENERATOR CAN

DO

ldquo

ldquo

Traffic Generator tool can generate and send RAW packets over specific ports It also collects latency and jitter values txrx rates counts lost packets and

detects Out-of-Order (OOO) packets

Traffic Generator can be used similar to bandwidth test tool as well as generate packets that will be routed back to packet generator for advanced

status collection

DEVICE UNDER TEST

TRAFFIC GENERATOR

Test performance of device or system before migrate to production

infrastructure such as

bull PPS (Packet Per Second)

bull Throughput Bandwidth

bull CPU

bull Hardware Encryption

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 5: MUM Europe 2017 - Traffic Generator Case Study

COMPANY PROFILE

PROJECT BASEDbull Fiber optic installation outdor and

indoor (Hotel and Office Building)

bull Wireless installation Rural area and

City

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

CONSULTANTbull Mikrotik Products

bull Licensed Antennas

bull Ipv4 Brocker

bull Advanced monitoring integrations

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

TRAININGbull Official Mikrotik Training Partner

with three different languages and

modules (English Indonesia and

Spanish)

bull Courses on premises of companies in

Europe and middle east

bull Specialized in IPv6

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

AGENDA

Traffic Generator Introduction Special Use Case Example

Objetive

The goal of this presentation is to explain the operation of the traffic generator

11

Problem

What to do when I need to test or audit whether a router or a system is working correctly

12

Symptoms

We have a complex configuration and we have no idea how to test it

13

Solution

Traffic generator

14

TRAFFIC GENERATORINTRODUCTION

WHAT IS TRAFFIC

GENERATOR

Traffic Generator is a tool that allows to evaluate performance of DUT (Device Under Test) or SUT (System Under Test)

ldquoldquohttpswikimikrotikcomwikiManualToolsTraffic_Generator

WHATrsquoS TRAFFIC GENERATOR CAN

DO

ldquo

ldquo

Traffic Generator tool can generate and send RAW packets over specific ports It also collects latency and jitter values txrx rates counts lost packets and

detects Out-of-Order (OOO) packets

Traffic Generator can be used similar to bandwidth test tool as well as generate packets that will be routed back to packet generator for advanced

status collection

DEVICE UNDER TEST

TRAFFIC GENERATOR

Test performance of device or system before migrate to production

infrastructure such as

bull PPS (Packet Per Second)

bull Throughput Bandwidth

bull CPU

bull Hardware Encryption

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 6: MUM Europe 2017 - Traffic Generator Case Study

PROJECT BASEDbull Fiber optic installation outdor and

indoor (Hotel and Office Building)

bull Wireless installation Rural area and

City

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

CONSULTANTbull Mikrotik Products

bull Licensed Antennas

bull Ipv4 Brocker

bull Advanced monitoring integrations

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

TRAININGbull Official Mikrotik Training Partner

with three different languages and

modules (English Indonesia and

Spanish)

bull Courses on premises of companies in

Europe and middle east

bull Specialized in IPv6

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

AGENDA

Traffic Generator Introduction Special Use Case Example

Objetive

The goal of this presentation is to explain the operation of the traffic generator

11

Problem

What to do when I need to test or audit whether a router or a system is working correctly

12

Symptoms

We have a complex configuration and we have no idea how to test it

13

Solution

Traffic generator

14

TRAFFIC GENERATORINTRODUCTION

WHAT IS TRAFFIC

GENERATOR

Traffic Generator is a tool that allows to evaluate performance of DUT (Device Under Test) or SUT (System Under Test)

ldquoldquohttpswikimikrotikcomwikiManualToolsTraffic_Generator

WHATrsquoS TRAFFIC GENERATOR CAN

DO

ldquo

ldquo

Traffic Generator tool can generate and send RAW packets over specific ports It also collects latency and jitter values txrx rates counts lost packets and

detects Out-of-Order (OOO) packets

Traffic Generator can be used similar to bandwidth test tool as well as generate packets that will be routed back to packet generator for advanced

status collection

DEVICE UNDER TEST

TRAFFIC GENERATOR

Test performance of device or system before migrate to production

infrastructure such as

bull PPS (Packet Per Second)

bull Throughput Bandwidth

bull CPU

bull Hardware Encryption

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 7: MUM Europe 2017 - Traffic Generator Case Study

CONSULTANTbull Mikrotik Products

bull Licensed Antennas

bull Ipv4 Brocker

bull Advanced monitoring integrations

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

TRAININGbull Official Mikrotik Training Partner

with three different languages and

modules (English Indonesia and

Spanish)

bull Courses on premises of companies in

Europe and middle east

bull Specialized in IPv6

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

AGENDA

Traffic Generator Introduction Special Use Case Example

Objetive

The goal of this presentation is to explain the operation of the traffic generator

11

Problem

What to do when I need to test or audit whether a router or a system is working correctly

12

Symptoms

We have a complex configuration and we have no idea how to test it

13

Solution

Traffic generator

14

TRAFFIC GENERATORINTRODUCTION

WHAT IS TRAFFIC

GENERATOR

Traffic Generator is a tool that allows to evaluate performance of DUT (Device Under Test) or SUT (System Under Test)

ldquoldquohttpswikimikrotikcomwikiManualToolsTraffic_Generator

WHATrsquoS TRAFFIC GENERATOR CAN

DO

ldquo

ldquo

Traffic Generator tool can generate and send RAW packets over specific ports It also collects latency and jitter values txrx rates counts lost packets and

detects Out-of-Order (OOO) packets

Traffic Generator can be used similar to bandwidth test tool as well as generate packets that will be routed back to packet generator for advanced

status collection

DEVICE UNDER TEST

TRAFFIC GENERATOR

Test performance of device or system before migrate to production

infrastructure such as

bull PPS (Packet Per Second)

bull Throughput Bandwidth

bull CPU

bull Hardware Encryption

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 8: MUM Europe 2017 - Traffic Generator Case Study

TRAININGbull Official Mikrotik Training Partner

with three different languages and

modules (English Indonesia and

Spanish)

bull Courses on premises of companies in

Europe and middle east

bull Specialized in IPv6

b u s i n e s s i n q u i r i e S h e l l o f i b e r c l i c o m

AGENDA

Traffic Generator Introduction Special Use Case Example

Objetive

The goal of this presentation is to explain the operation of the traffic generator

11

Problem

What to do when I need to test or audit whether a router or a system is working correctly

12

Symptoms

We have a complex configuration and we have no idea how to test it

13

Solution

Traffic generator

14

TRAFFIC GENERATORINTRODUCTION

WHAT IS TRAFFIC

GENERATOR

Traffic Generator is a tool that allows to evaluate performance of DUT (Device Under Test) or SUT (System Under Test)

ldquoldquohttpswikimikrotikcomwikiManualToolsTraffic_Generator

WHATrsquoS TRAFFIC GENERATOR CAN

DO

ldquo

ldquo

Traffic Generator tool can generate and send RAW packets over specific ports It also collects latency and jitter values txrx rates counts lost packets and

detects Out-of-Order (OOO) packets

Traffic Generator can be used similar to bandwidth test tool as well as generate packets that will be routed back to packet generator for advanced

status collection

DEVICE UNDER TEST

TRAFFIC GENERATOR

Test performance of device or system before migrate to production

infrastructure such as

bull PPS (Packet Per Second)

bull Throughput Bandwidth

bull CPU

bull Hardware Encryption

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 9: MUM Europe 2017 - Traffic Generator Case Study

AGENDA

Traffic Generator Introduction Special Use Case Example

Objetive

The goal of this presentation is to explain the operation of the traffic generator

11

Problem

What to do when I need to test or audit whether a router or a system is working correctly

12

Symptoms

We have a complex configuration and we have no idea how to test it

13

Solution

Traffic generator

14

TRAFFIC GENERATORINTRODUCTION

WHAT IS TRAFFIC

GENERATOR

Traffic Generator is a tool that allows to evaluate performance of DUT (Device Under Test) or SUT (System Under Test)

ldquoldquohttpswikimikrotikcomwikiManualToolsTraffic_Generator

WHATrsquoS TRAFFIC GENERATOR CAN

DO

ldquo

ldquo

Traffic Generator tool can generate and send RAW packets over specific ports It also collects latency and jitter values txrx rates counts lost packets and

detects Out-of-Order (OOO) packets

Traffic Generator can be used similar to bandwidth test tool as well as generate packets that will be routed back to packet generator for advanced

status collection

DEVICE UNDER TEST

TRAFFIC GENERATOR

Test performance of device or system before migrate to production

infrastructure such as

bull PPS (Packet Per Second)

bull Throughput Bandwidth

bull CPU

bull Hardware Encryption

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 10: MUM Europe 2017 - Traffic Generator Case Study

Objetive

The goal of this presentation is to explain the operation of the traffic generator

11

Problem

What to do when I need to test or audit whether a router or a system is working correctly

12

Symptoms

We have a complex configuration and we have no idea how to test it

13

Solution

Traffic generator

14

TRAFFIC GENERATORINTRODUCTION

WHAT IS TRAFFIC

GENERATOR

Traffic Generator is a tool that allows to evaluate performance of DUT (Device Under Test) or SUT (System Under Test)

ldquoldquohttpswikimikrotikcomwikiManualToolsTraffic_Generator

WHATrsquoS TRAFFIC GENERATOR CAN

DO

ldquo

ldquo

Traffic Generator tool can generate and send RAW packets over specific ports It also collects latency and jitter values txrx rates counts lost packets and

detects Out-of-Order (OOO) packets

Traffic Generator can be used similar to bandwidth test tool as well as generate packets that will be routed back to packet generator for advanced

status collection

DEVICE UNDER TEST

TRAFFIC GENERATOR

Test performance of device or system before migrate to production

infrastructure such as

bull PPS (Packet Per Second)

bull Throughput Bandwidth

bull CPU

bull Hardware Encryption

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 11: MUM Europe 2017 - Traffic Generator Case Study

Problem

What to do when I need to test or audit whether a router or a system is working correctly

12

Symptoms

We have a complex configuration and we have no idea how to test it

13

Solution

Traffic generator

14

TRAFFIC GENERATORINTRODUCTION

WHAT IS TRAFFIC

GENERATOR

Traffic Generator is a tool that allows to evaluate performance of DUT (Device Under Test) or SUT (System Under Test)

ldquoldquohttpswikimikrotikcomwikiManualToolsTraffic_Generator

WHATrsquoS TRAFFIC GENERATOR CAN

DO

ldquo

ldquo

Traffic Generator tool can generate and send RAW packets over specific ports It also collects latency and jitter values txrx rates counts lost packets and

detects Out-of-Order (OOO) packets

Traffic Generator can be used similar to bandwidth test tool as well as generate packets that will be routed back to packet generator for advanced

status collection

DEVICE UNDER TEST

TRAFFIC GENERATOR

Test performance of device or system before migrate to production

infrastructure such as

bull PPS (Packet Per Second)

bull Throughput Bandwidth

bull CPU

bull Hardware Encryption

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 12: MUM Europe 2017 - Traffic Generator Case Study

Symptoms

We have a complex configuration and we have no idea how to test it

13

Solution

Traffic generator

14

TRAFFIC GENERATORINTRODUCTION

WHAT IS TRAFFIC

GENERATOR

Traffic Generator is a tool that allows to evaluate performance of DUT (Device Under Test) or SUT (System Under Test)

ldquoldquohttpswikimikrotikcomwikiManualToolsTraffic_Generator

WHATrsquoS TRAFFIC GENERATOR CAN

DO

ldquo

ldquo

Traffic Generator tool can generate and send RAW packets over specific ports It also collects latency and jitter values txrx rates counts lost packets and

detects Out-of-Order (OOO) packets

Traffic Generator can be used similar to bandwidth test tool as well as generate packets that will be routed back to packet generator for advanced

status collection

DEVICE UNDER TEST

TRAFFIC GENERATOR

Test performance of device or system before migrate to production

infrastructure such as

bull PPS (Packet Per Second)

bull Throughput Bandwidth

bull CPU

bull Hardware Encryption

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 13: MUM Europe 2017 - Traffic Generator Case Study

Solution

Traffic generator

14

TRAFFIC GENERATORINTRODUCTION

WHAT IS TRAFFIC

GENERATOR

Traffic Generator is a tool that allows to evaluate performance of DUT (Device Under Test) or SUT (System Under Test)

ldquoldquohttpswikimikrotikcomwikiManualToolsTraffic_Generator

WHATrsquoS TRAFFIC GENERATOR CAN

DO

ldquo

ldquo

Traffic Generator tool can generate and send RAW packets over specific ports It also collects latency and jitter values txrx rates counts lost packets and

detects Out-of-Order (OOO) packets

Traffic Generator can be used similar to bandwidth test tool as well as generate packets that will be routed back to packet generator for advanced

status collection

DEVICE UNDER TEST

TRAFFIC GENERATOR

Test performance of device or system before migrate to production

infrastructure such as

bull PPS (Packet Per Second)

bull Throughput Bandwidth

bull CPU

bull Hardware Encryption

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 14: MUM Europe 2017 - Traffic Generator Case Study

TRAFFIC GENERATORINTRODUCTION

WHAT IS TRAFFIC

GENERATOR

Traffic Generator is a tool that allows to evaluate performance of DUT (Device Under Test) or SUT (System Under Test)

ldquoldquohttpswikimikrotikcomwikiManualToolsTraffic_Generator

WHATrsquoS TRAFFIC GENERATOR CAN

DO

ldquo

ldquo

Traffic Generator tool can generate and send RAW packets over specific ports It also collects latency and jitter values txrx rates counts lost packets and

detects Out-of-Order (OOO) packets

Traffic Generator can be used similar to bandwidth test tool as well as generate packets that will be routed back to packet generator for advanced

status collection

DEVICE UNDER TEST

TRAFFIC GENERATOR

Test performance of device or system before migrate to production

infrastructure such as

bull PPS (Packet Per Second)

bull Throughput Bandwidth

bull CPU

bull Hardware Encryption

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 15: MUM Europe 2017 - Traffic Generator Case Study

WHAT IS TRAFFIC

GENERATOR

Traffic Generator is a tool that allows to evaluate performance of DUT (Device Under Test) or SUT (System Under Test)

ldquoldquohttpswikimikrotikcomwikiManualToolsTraffic_Generator

WHATrsquoS TRAFFIC GENERATOR CAN

DO

ldquo

ldquo

Traffic Generator tool can generate and send RAW packets over specific ports It also collects latency and jitter values txrx rates counts lost packets and

detects Out-of-Order (OOO) packets

Traffic Generator can be used similar to bandwidth test tool as well as generate packets that will be routed back to packet generator for advanced

status collection

DEVICE UNDER TEST

TRAFFIC GENERATOR

Test performance of device or system before migrate to production

infrastructure such as

bull PPS (Packet Per Second)

bull Throughput Bandwidth

bull CPU

bull Hardware Encryption

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 16: MUM Europe 2017 - Traffic Generator Case Study

Traffic Generator is a tool that allows to evaluate performance of DUT (Device Under Test) or SUT (System Under Test)

ldquoldquohttpswikimikrotikcomwikiManualToolsTraffic_Generator

WHATrsquoS TRAFFIC GENERATOR CAN

DO

ldquo

ldquo

Traffic Generator tool can generate and send RAW packets over specific ports It also collects latency and jitter values txrx rates counts lost packets and

detects Out-of-Order (OOO) packets

Traffic Generator can be used similar to bandwidth test tool as well as generate packets that will be routed back to packet generator for advanced

status collection

DEVICE UNDER TEST

TRAFFIC GENERATOR

Test performance of device or system before migrate to production

infrastructure such as

bull PPS (Packet Per Second)

bull Throughput Bandwidth

bull CPU

bull Hardware Encryption

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 17: MUM Europe 2017 - Traffic Generator Case Study

WHATrsquoS TRAFFIC GENERATOR CAN

DO

ldquo

ldquo

Traffic Generator tool can generate and send RAW packets over specific ports It also collects latency and jitter values txrx rates counts lost packets and

detects Out-of-Order (OOO) packets

Traffic Generator can be used similar to bandwidth test tool as well as generate packets that will be routed back to packet generator for advanced

status collection

DEVICE UNDER TEST

TRAFFIC GENERATOR

Test performance of device or system before migrate to production

infrastructure such as

bull PPS (Packet Per Second)

bull Throughput Bandwidth

bull CPU

bull Hardware Encryption

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 18: MUM Europe 2017 - Traffic Generator Case Study

ldquo

ldquo

Traffic Generator tool can generate and send RAW packets over specific ports It also collects latency and jitter values txrx rates counts lost packets and

detects Out-of-Order (OOO) packets

Traffic Generator can be used similar to bandwidth test tool as well as generate packets that will be routed back to packet generator for advanced

status collection

DEVICE UNDER TEST

TRAFFIC GENERATOR

Test performance of device or system before migrate to production

infrastructure such as

bull PPS (Packet Per Second)

bull Throughput Bandwidth

bull CPU

bull Hardware Encryption

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 19: MUM Europe 2017 - Traffic Generator Case Study

DEVICE UNDER TEST

TRAFFIC GENERATOR

Test performance of device or system before migrate to production

infrastructure such as

bull PPS (Packet Per Second)

bull Throughput Bandwidth

bull CPU

bull Hardware Encryption

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 20: MUM Europe 2017 - Traffic Generator Case Study

Test performance of link (wired or wireless) between sites

bull Latency

bull Packet loss

bull Jitter

bull Bandwidth

SITE 1 SITE 2

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 21: MUM Europe 2017 - Traffic Generator Case Study

DEVICE UNDER TEST

TRAFFIC GENERATOR TRAFFIC GENERATOR TRAFFIC GENERATOR

Polices (firewall or qos) test performance of device

bull Creating ldquofabricatedrdquopackets

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 22: MUM Europe 2017 - Traffic Generator Case Study

EXAMPLE

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 23: MUM Europe 2017 - Traffic Generator Case Study

CASE 1

Simple Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 24: MUM Europe 2017 - Traffic Generator Case Study

DEVICE UNDER TESTTRAFFIC GENERATOR

1010024

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 25: MUM Europe 2017 - Traffic Generator Case Study

ip addressadd address=1010124 interface=ether1 network=10100

ip addressadd address=1010224 interface=ether1 network=10100

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 26: MUM Europe 2017 - Traffic Generator Case Study

PORT TEMPLATE STREAM

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 27: MUM Europe 2017 - Traffic Generator Case Study

tool traffic-generator portadd interface=ether1 name=port1

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 28: MUM Europe 2017 - Traffic Generator Case Study

tool traffic-generator packet-templateadd name=template-1 port=port1 ip-dst=10102 ip-src=10101

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 29: MUM Europe 2017 - Traffic Generator Case Study

tool traffic-generator streamadd name=stream-1 packet-size=1500 tx-template=template-1

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 30: MUM Europe 2017 - Traffic Generator Case Study

WHY TXRX TRAFFICrsquoS NOT EQUAL

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 31: MUM Europe 2017 - Traffic Generator Case Study

Because we only send (tx) traffic to the destination address as above DUTSUT only

receive traffic without sending the packet back

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 32: MUM Europe 2017 - Traffic Generator Case Study

We change the template in the ldquoIPrdquo section like this

Ip address ether1 on Traffic-Generator device

Ip address ether1 on DUTSUT device

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 33: MUM Europe 2017 - Traffic Generator Case Study

CASE 2

Multi-Port Traffic Generator

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 34: MUM Europe 2017 - Traffic Generator Case Study

DEVICE UNDER TESTTRAFFIC GENERATOR

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 35: MUM Europe 2017 - Traffic Generator Case Study

ip addressadd address=1010224 interface=ether1 network=10100add address=1020224 interface=ether2 network=10200add address=1030224 interface=ether3 network=10300

ip addressadd address=1010124 interface=ether1 network=10100add address=1020124 interface=ether2 network=10200add address=1030124 interface=ether3 network=10300

ipv6 addressadd address=200110101 interface=ether1add address=200110201 interface=ether2add address=200110301 interface=ether3

ipv6 addressadd address=200110102 interface=ether1add address=200110202 interface=ether2add address=200110302 interface=ether3

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 36: MUM Europe 2017 - Traffic Generator Case Study

TEMPLATES START

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 37: MUM Europe 2017 - Traffic Generator Case Study

TRAFFIC GENERATOR

DEVICE UNDER TEST

PORT 1 PORT 2 PORT 3

PORT 1 PORT 2 PORT 3

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 38: MUM Europe 2017 - Traffic Generator Case Study

tool traffic-generator packet-templateadd header-stack=macipipv6udp ip-dst=10201 ip-gateway=10102 ipv6-dst=20011021128 ipv6-gateway=20011012 name=port1-to-port2add header-stack=macipipv6tcp ip-dst=10301 ip-gateway=10102 ipv6-dst=20011031128 ipv6-gateway=20011012 name=port1-to-port3add header-stack=macipipv6raw ip-dst=10101 ip-gateway=10202 ipv6-dst=20011011128 ipv6-gateway=20011022 name=port2-to-port1add header-stack=macipv6ipudp ip-dst=10301 ip-gateway=10202 ipv6-dst=20011031128 ipv6-gateway=20011022 name=port2-to-port3add header-stack=macipv6iptcp ip-dst=10101 ip-gateway=10302 ipv6-dst=20011011128 ipv6-gateway=20011032 name=port3-to-port1add header-stack=macipv6ipraw ip-dst=10201 ip-gateway=10302 ipv6-dst=20011021128 ipv6-gateway=20011032 name=port3-to-port2

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 39: MUM Europe 2017 - Traffic Generator Case Study

CASE 3

Fabricated Packets test

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 40: MUM Europe 2017 - Traffic Generator Case Study

In this case we wil l try a queue tree configuration that prioritizes voice traffic QoS router has

mangle rules and queue tree l imitations

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 41: MUM Europe 2017 - Traffic Generator Case Study

101000024

1000024

1010024

2000010

1010100

101000100

DUT

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 42: MUM Europe 2017 - Traffic Generator Case Study

In this secenario we wil l generates three diferentpackets

bull Tw o p a c ke t s ge n e ra t e d b y ( I P - P H O N E _ S I M U L ATO R ) s p e c i f i e d l i ke R T P a n d S I P p a c ke t s

bull O n e p a c ke t ge n e ra t e d b y ( I N T R U D E R ) ra n d o m p a c ke t l i ke s p o o f i n g

SCENARIO

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 43: MUM Europe 2017 - Traffic Generator Case Study

ip addressadd address=101010024 interface=ether1 network=10100

IP-PHONE_SIMULATOR

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 44: MUM Europe 2017 - Traffic Generator Case Study

bull RTP CALL vo ice audio data wi l l be marked by DSCP va lue of 46 DSCP va lue of 46 resul ts in a ToS byte va lue of 184 EF=0xB8

bull SIP CALL s igna l ing messages wi l l be marked by DSCP va lue of 26A DSCP va lue of 26 resu l ts in a ToS byte va lue of 104 AF31=0x68 (=104)75

CREATE FABRICATED VOIP TRAFIC

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 45: MUM Europe 2017 - Traffic Generator Case Study

tool traffic-generator packet-templateadd ip-dscp=184 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_RTP udp-dst-port=16384-32767add ip-dscp=104 ip-dst=101000100 ip-gateway=10101 ip-protocol=udp name=VOIP_SIP udp-dst-port=50605061

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 46: MUM Europe 2017 - Traffic Generator Case Study

INTRUDER

ip addressadd address=200001024 interface=ether1 network=200000

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 47: MUM Europe 2017 - Traffic Generator Case Study

bull Create random RAW packet in Traff ic -Generator

CREATE FABRICATED RANDOM TRAFIC

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 48: MUM Europe 2017 - Traffic Generator Case Study

tool traffic-generator packet-templateadd header-stack=macipraw ip-dst=101000100 ip-gateway=200001 name=spooftool traffic-generator stream add name=stream-1 packet-size=1500 tx-template=spoof

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 49: MUM Europe 2017 - Traffic Generator Case Study

DUTSUT

ip addressadd address=101000124 comment=VOIP SERVER interface=ether2 network=1010000add address=1000124 comment=INTERNET interface=ether1 network=10000add address=1010124 comment=CLIENT interface=ether3 network=10100

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 50: MUM Europe 2017 - Traffic Generator Case Study

bull Create two mangle for VOIP and one mangle for rest of packets dest inated to VOIP Server

bull Create three queue -treebull One parent queue ( PBX_Traff ic )bull One queue for rest packets (REST)bull One queue for VOIP packets (VOIP)

CREATE MANGLE AND QUEUE TREE

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 51: MUM Europe 2017 - Traffic Generator Case Study

ip firewall mangleadd action=mark-packet chain=prerouting comment=VOIP RULES dscp=46 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting dscp=26 dst-address=101000100 new-packet-mark=voip-packets passthrough=noadd action=mark-packet chain=prerouting comment=REST RULES dst-address=101000100 new-packet-mark=rest-packets passthrough=no

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 52: MUM Europe 2017 - Traffic Generator Case Study

queue treeadd name=PBX_Traffic parent=globaladd limit-at=5M max-limit=10M name=REST packet-mark=rest-packets parent=PBX_Trafficadd limit-at=1M max-limit=1M name=VOIP packet-mark=voip-packets parent=PBX_Traffic priority=1

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 53: MUM Europe 2017 - Traffic Generator Case Study

LAUNCH SIMULATION

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 54: MUM Europe 2017 - Traffic Generator Case Study

bull Launch t raff ic -generator f rom ldquo INTRUDERrdquo with packets 20 mbps

bull Launch t raff ic -generator f rom ldquo IP -PHONE_SIMULATORrdquo with 120 kbps t raff ic

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 55: MUM Europe 2017 - Traffic Generator Case Study

INTRUDER

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 56: MUM Europe 2017 - Traffic Generator Case Study

IP-PHONE SIMULATOR

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 57: MUM Europe 2017 - Traffic Generator Case Study

DUT

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 58: MUM Europe 2017 - Traffic Generator Case Study

CASE 4

Testing wireless

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 59: MUM Europe 2017 - Traffic Generator Case Study

Station

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 60: MUM Europe 2017 - Traffic Generator Case Study

AP

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 61: MUM Europe 2017 - Traffic Generator Case Study

Traffic generator

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 62: MUM Europe 2017 - Traffic Generator Case Study

Stats

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 63: MUM Europe 2017 - Traffic Generator Case Study

Stats

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 64: MUM Europe 2017 - Traffic Generator Case Study

CASE 5

Injecting pcap

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 65: MUM Europe 2017 - Traffic Generator Case Study

What is pcap

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 66: MUM Europe 2017 - Traffic Generator Case Study

How can I generate pcapcaptures

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 67: MUM Europe 2017 - Traffic Generator Case Study

Inject pcap

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 68: MUM Europe 2017 - Traffic Generator Case Study

Inject pcap

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 69: MUM Europe 2017 - Traffic Generator Case Study

Inject pcap

Conclusion

Grazie milleJose romanfiberc l i com

Page 70: MUM Europe 2017 - Traffic Generator Case Study

Conclusion

Grazie milleJose romanfiberc l i com

Page 71: MUM Europe 2017 - Traffic Generator Case Study

Grazie milleJose romanfiberc l i com