标签:span src ethernet toc eth flags tcp port log
e = ethernet.ethernet(dst=_eth.src, src=_eth.dst, ethertype=_eth.ethertype) i = ipv4.ipv4(dst=‘192.168.1.1‘,#_ipv4.src, src=_ipv4.dst, proto=_ipv4.proto, flags=_ipv4.flags ) t = tcp.tcp( dst_port=_tcp.src_port, src_port=_tcp.dst_port, seq=0, ack=1 ) t.bits = t.bits | tcp.TCP_ACK pkt = packet.Packet() pkt.add_protocol(e) pkt.add_protocol(i) pkt.add_protocol(t)
标签:span src ethernet toc eth flags tcp port log
原文地址:http://www.cnblogs.com/hwy89289709/p/6917948.html