-
Notifications
You must be signed in to change notification settings - Fork 11
Expand file tree
/
Copy pathreset
More file actions
26 lines (20 loc) · 728 Bytes
/
Copy pathreset
File metadata and controls
26 lines (20 loc) · 728 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/usr/bin/env bash
#Reset rules script by Gaetan. Add discord: 'Gaetan#0099' to get help.
echo "Reset loading..."
#------------------------------------------------------------------------------------------
#Variable
IPTABLES="sudo iptables" # The location of iptables
#------------------------------------------------------------------------------------------
# Reset the rules
$IPTABLES -t filter -F
$IPTABLES -t filter -X
$IPTABLES -t mangle -F
$IPTABLES -t mangle -X
$IPTABLES -t raw -F
$IPTABLES -t raw -X
echo "Rules#1 - The rules was reset."
# Accept all
$IPTABLES -t filter -P INPUT ACCEPT
$IPTABLES -t filter -P FORWARD ACCEPT
$IPTABLES -t filter -P OUTPUT ACCEPT
echo "Rules#2 - All the trafic was allowed."