Created
October 23, 2020 07:40
-
-
Save iamshreeram/d60327bcc7e03acb4cb9da032edd62d4 to your computer and use it in GitHub Desktop.
Simple python code to spoof udp source and destination
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from scapy.all import * | |
import time | |
ip = IP(dst='127.0.0.127', src='10.99.99.99') | |
udp = UDP(sport=321,dport=123) | |
payload = '\x01\x0f' | |
packet = ip/udp/payload | |
send(packet) | |
while(True): | |
send(packet) | |
time.sleep(1) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment