Changes between Version 10 and Version 11 of Csle2022/Agenda/FW


Ignore:
Timestamp:
Oct 20, 2022, 11:33:12 AM (2 years ago)
Author:
geethike
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Csle2022/Agenda/FW

    v10 v11  
    103103sudo iptables -A INPUT -s 192.168.1.3 -j DROP
    104104}}}
     105This may look complicated, but most of it will make sense when we go over the components:-
     106
     107'''-A INPUT :-'''
     108
     109The flag -A is used to append a rule to the end of a chain. This part of the command tells the iptable that we want to add a rule to the end of the INPUT chain.
     110
     111'''-I INPUT:-'''
     112In this flag the rules are added to the top of the chain.
     113
     114'''-s 192.168.1.3:-'''
     115The flag -s is used to specify the source of the packet. This tells the iptable to look for the packets coming from the source 192.168.1.3
     116
     117'''-j DROP'''
     118This specifies what the iptable should do with the packet.
     119
     120In short, the above command adds a rule to the INPUT chain which says, if any packet arrives whose source address is 192.168.1.3 then drop that packet, that means do not allow the packet reach the computer.
     121
     122Once you execute the above command you can see the changes by using the command:-
     123{{{
     124sudo iptables -L
     125}}}