View Single Post
Old 06-10-2012, 06:02 AM   #8
aritzilla
Member Retired
aritzilla began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Jun 2012
Device: PRS-T1
I have root my T1 using the last rupor´s version and i´m looking for use ftp.

I have modified firewall. sh file, trying this

1 - modify # iptables -P INPUT DROP:

2 - modify firewall.sh writing

iptables -P INPUT ACCEPT

3 - install terminal emulator and write:

su
iptables -P INPUT ACCEPT


But nothing works. I Can´t use FTP.

What do i do wrong?

Sorry my bad english. thanks.

Actually this is my firewall.sh

#!/system/bin/sh



flush()
{
# flush all rules('filter' table)
iptables -F
iptables -X
iptables -Z
# reset default chain policy('filter' table)
iptables -P INPUT ACCEPT
iptables -P FORWARD ACCEPT
iptables -P OUTPUT ACCEPT

# # flush all rules('mangle' table)
# iptables -t mangle -F
# iptables -t mangle -X
# iptables -t mangle -Z
# # reset default chain policy('mangle' table)
# iptables -t mangle -P PREROUTING ACCEPT
# iptables -t mangle -P INPUT ACCEPT
# iptables -t mangle -P FORWARD ACCEPT
# iptables -t mangle -P OUTPUT ACCEPT
# iptables -t mangle -P POSTROUTING ACCEPT
}



build()
{
# default policy
flush
# iptables -P INPUT DROP #Se ha puesto como comentario esta linea para permitir usar samba en el T1; (se permite el tráfico de entrada al dispositivo, DROP lo rechazaba)
iptables -P FORWARD DROP
iptables -P OUTPUT DROP

# logging table
iptables -N log
iptables -A log -j LOG

# loopback table
iptables -N loopback
iptables -A loopback -s localhost -d localhost -j ACCEPT
iptables -A INPUT -i lo -j loopback
iptables -A OUTPUT -o lo -j loopback

# stateful inspection
iptables -A INPUT -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A INPUT -j log

# accept application protocol
iptables -A OUTPUT -j ACCEPT
iptables -A OUTPUT -j log


# # disable TCP ECN for Wi-Fi
# iptables -t mangle -A OUTPUT -o wlan+ -p tcp -j ECN --ecn-tcp-remove
}



disable_log()
{
iptables -F log
}



enable_log()
{
disable_log
iptables -A log -j LOG
}




case "$1" in
-f)
flush
;;

-l)
disable_log
;;

-L)
enable_log
;;

*)
build 2>/dev/null
;;
esac
aritzilla is offline   Reply With Quote