lianghu / ostinato

Automatically exported from code.google.com/p/ostinato
GNU General Public License v3.0
0 stars 0 forks source link

Discrepencies between tcpdumped packet and ostinato received packet #148

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Running Ostinato on Fedora20
2. Running ostinato python script (modified example.py to use hexDump protocol 
to send customized traffic) to Send L2 eth packet using hexDump protocol on one 
port and receive it on the other port on the same PC
3. tcpdump on rx port, compare hex value of the tcpdumped packet and packet 
ostinato received

What is the expected output? What do you see instead?
tcpdumped packet should be same as the one ostinato received.

I am seeing packet being massaged by ostinato, dst mac being changed and a 
16bits  0x0000 inserted between src mac and eth type field. Please see detailed 
packets below:

TCPDUMP'ed packet on rx port :
15:26:38.789253 IP 2.2.2.2 > 1.1.1.1:  ip 50
        0x0000:  0218 ba87 edd1 0201 0203 0310 0800 4500
        0x0010:  0046 04d2 0000 7f00 30e1 0202 0202 0101
        0x0020:  0101 6162 6364 6566 6768 696a 6b6c 6d6e
        0x0030:  6f70 7172 7374 7576 7778 797a 2321 3c61
        0x0040:  743e 2023 2425 5e26 2a28 293f 3e3c 7b7d
        0x0050:  2b5f 5d5b

Tshark'ed dump of packets Ostinato received on rx port and stored in pcap file 

0000  00 03 00 01 00 06 02 01 02 03 03 10 00 00 08 00   ................
0010  45 00 00 46 04 d2 00 00 7f 00 30 e1 02 02 02 02   E..F......0.....
0020  01 01 01 01 61 62 63 64 65 66 67 68 69 6a 6b 6c   ....abcdefghijkl
0030  6d 6e 6f 70 71 72 73 74 75 76 77 78 79 7a 23 21   mnopqrstuvwxyz#!
0040  3c 61 74 3e 20 23 24 25 5e 26 2a 28 29 3f 3e 3c   <at> #$%^&*()?><
0050  7b 7d 2b 5f 5d 5b                                 {}+_][

What version and revision of the product are you using (available in the
About dialog)? On what operating system?
I'm running ostinato version 0.6 on Fedora release 20 (Heisenbug)

Please provide any additional information below.

Original issue reported on code.google.com by wanghanw...@gmail.com on 13 Mar 2015 at 11:20

GoogleCodeExporter commented 9 years ago
Hmm ... that's strange

* Can you try the same using the GUI instead of the python script? Use 
start/stop/get capture packet using the GUI. Do you still see the problem?
* Can you attach your python script here for me to try?

Original comment by pstav...@gmail.com on 14 Mar 2015 at 4:45

GoogleCodeExporter commented 9 years ago
Please see attached as the python scripts.
packatGenrator is modified based on example.py, by importing hexdump protocol 
to send traffic. 
controller_test.py, is nothing but calls packetGenerator to send a packet and 
receive back.

Original comment by wanghanw...@gmail.com on 16 Mar 2015 at 6:08

Attachments: