title: Scapy packet sent cannot be received
body: <p>I'm trying to send UDP Packets with scapy with the following command:</p>
  
  <pre><code>&gt;&gt; send(IP(dst="127.0.0.1",src="111.111.111.111")/UDP(dport=5005)/"Hello")
  .
  Sent 1 packets.
  </code></pre>
  
  <p>And from <code>tcpdump</code> I can see:</p>
  
  <pre><code>22:02:58.384730 IP 111.111.111.111.domain &gt; localhost.5005: [|domain]
  </code></pre>
  
  <p>I'm trying to receive this packet with the following code:</p>
  
  <pre><code>import socket
  
  UDP_IP = "127.0.0.1"
  UDP_PORT = 5005
  
  sock = socket.socket(socket.AF_INET, # Internet
                       socket.SOCK_DGRAM) # UDP
  sock.bind((UDP_IP, UDP_PORT))
  
  while True:
      data, addr = sock.recvfrom(1024) # buffer size is 1024 bytes
      print "received message:", data
  </code></pre>
  
  <p>But cannot receive the message. </p>
  
  <p>I have tested the  network by sending udp packets normally with the following code and the packet can be received:</p>
  
  <pre><code>import socket
  import time
  
  UDP_IP = "127.0.0.1"
  UDP_PORT = 5005
  
  print "UDP target IP:", UDP_IP
  print "UDP target port:", UDP_PORT
  
  sock = socket.socket(socket.AF_INET, # Internet
                       socket.SOCK_DGRAM) # UDP
  num = 0
  while True:
    sock.sendto(str(num), (UDP_IP, UDP_PORT))
    print "Message sent: " + str(num)
    num += 1
    time.sleep(1)
  </code></pre>
  
  <p>Any help will be greatly appreciated.</p>
  
  <p>----------------Updates-----------------------</p>
  
  <p>A packet sent by Scapy that can not be received:</p>
  
  <pre><code>13:22:52.984862 IP (tos 0x0, ttl 64, id 1, offset 0, flags [DF], proto UDP (17), length 33)
      127.0.0.1.5555 &gt; 127.0.0.1.12345: [udp sum ok] UDP, length 5
      0x0000:  4500 0021 0001 4000 4011 3cc9 7f00 0001  E..!..@.@.&lt;.....
      0x0010:  7f00 0001 15b3 3039 000d 9813 4865 6c6c  ......09....Hell
      0x0020:  6f     
  
                                o
  </code></pre>
  
  <p>While a packet sent by normal python script that can be received:</p>
  
  <pre><code>13:20:02.374481 IP (tos 0x0, ttl 64, id 0, offset 0, flags [DF], proto UDP (17), length 33)
      127.0.0.1.53143 &gt; 127.0.0.1.12345: [bad udp cksum 0xfe20 -&gt; 0xde2e!] UDP, length 5
      0x0000:  4500 0021 0000 4000 4011 3cca 7f00 0001  E..!..@.@.&lt;.....
      0x0010:  7f00 0001 cf97 3039 000d fe20 4865 6c6c  ......09....Hell
      0x0020:  6f
  </code></pre>