I want to built a fire wall using iptables. My condition is
" inbound to 192.168.0.2 with a port of 80 from
172.168.0.1 should accept"
Answer Posted / venkat
Command:
iptables -i INPUT -t filter -p tcp -s 172.168.0.1 -d
192.168.0.2 --dport 80 -j ACCEPT
Description:
-i --> Match the INPUT or inbound
-t --> Table name here default is filter
-p --> Protocol
-s --> Source IP
-d --> Destination IP
--dport --> Port number
-j --> Condition.
| Is This Answer Correct ? | 4 Yes | 0 No |
Post New Answer View All Answers
What is s in permission linux?
What is mkdir p linux?
How do you create a text file in linux?
Which command is used to uncompress gzip files?
What is 9 in kill?
How do you execute more than one command or program from a single command line entry?
What command would you use to create an empty file without opening it to edit it?
How do you kill a process in linux?
Does linux cp command overwrite?
What is apple llvm?
When and how linux developed?
What is clang space engineers?
What is make in linux?
Why makefile is used in linux?
How do you create a text file in linux terminal?