Is it possible to block an established ftp session?
We are setting up port forwarding in our linux box, and changed the listening server from port 21 to 4123. Enabled port forwarding:
ACCEPT tcp -- anywhere 192.168.1.62 tcp dpt:4123
Then we establish the ftp session.
Once we are connected, we delete the port forwarding entry, but the ftp session stays active. It only blocks (or doesn't port fwd) for new requests. We've tried adding a DROP chain in the iptables:
iptables -I PORTFWD 1 -p tcp --dport 21 -d 192.168.1.62 -m state --state ESTABLISHED,RELATED -j DROP
This is added during the active session but no luck in stopping the existing session. The session is still active. Is there a way to do this? Thanks.