iptables drop multiple port

Iptables DROP IP on Server

iptables -A INPUT -s 5.34.207.222/32 -j DROP 

 Iptables allow IP on Server

iptables -A INPUT -s 122.176.113.126/32 -j ACCEPT
iptables -A INPUT -s 127.0.0.1/32 -j ACCEPT

Iptables DROP multiple ports 

iptables -A INPUT -d 21.4.179.80/32 -p tcp -m multiport --dports 8080,8443 -j DROP

Share on Google Plus

About Penguin Technology

I am a passionate cloud and DevOps professional specializing in Linux and open-source solutions. Through this blog, I share my knowledge and experience with the community, offering tips and insights on cloud technologies and DevOps practices.
    Blogger Comment

1 comments:

  1. Excellent Blog.
    Learn Industrial Linux Training in Noida from Galaxy Cloud
    https://galaxycloud.in/linux-training.php

    ReplyDelete