Can't connect back to EC2 instance after port redirct #iptables #aws

https://askubuntu.com/q/1565654/612

Can't connect back to EC2 instance after port redirct

I am trying to run cowrie honeypot on aws instance. As instructed I added following rule on the instance. sudo iptables -t nat -A PREROUTING -p tcp --dport 22 -j REDIRECT --to-port 2222 I figured I

Ask Ubuntu