Skip to content

Instantly share code, notes, and snippets.

@ahmetozer
Created January 2, 2021 13:31
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ahmetozer/f4b88d76306a680ce5f8b7f0ac2bac76 to your computer and use it in GitHub Desktop.
Save ahmetozer/f4b88d76306a680ce5f8b7f0ac2bac76 to your computer and use it in GitHub Desktop.
Send udp packets in interval
#!/bin/bash
####
# ahmetozer.org
####
## Usage
# ./udp_test_package_loop.sh (send-interval) (remote-ip) (remote-port|default 53) (source-port|default 9000)
function fakeReq {
while true
do
echo " "
sleep $1
done
}
fakeReq $1 | nc -u $2 ${3-53} -p ${4-9000}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment