Skip to content

Instantly share code, notes, and snippets.

@Canx
Created September 4, 2018 20:07
Show Gist options
  • Save Canx/fc93bedc24a3d5694a06f7f146a53411 to your computer and use it in GitHub Desktop.
Save Canx/fc93bedc24a3d5694a06f7f146a53411 to your computer and use it in GitHub Desktop.
#!/bin/bash
exec 3>&1;
urls=$(dialog --title "URL accesibles" --inputbox "Indica las URL's que podrán ser accesibles (separadas por espacio)" 0 60 2>&1 1>&3);
exitcode=$?;
exec 3>&1;
for url in $urls; do
echo "iptables -I FORWARD -s $url -j ACCEPT";
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment