Open main menu

CDOT Wiki β

Changes

OPS235 Lab 7 - CentOS7 - HD2

374 bytes added, 16:53, 24 October 2016
no edit summary
# Issue the iptables command separately to display the rules for the '''OUTPUT''' chain and for the '''FORWARD''' chain.
# Issue the following command: <b><code><span style="pointer-events: none;cursor: default;color:#3366CC;font-size:1.2em;">iptables -L -v </span></code></b><br>What do you notice about this command as opposed to the first iptables command you issued? What sort of additional information does this command provide regarding affected packets?<br><br>
# Sometimes it may be useful to completely clear the rules for all or a particular chain. Note the options that can be used to clear (or flush) the iptables rules:,<br><br>'''Clearing (Flushing) iptables Rules:'''<br><table width="100%" cellpadding="10" cellspacing="0" border="1">
<tr><td width="30%">'''iptables -F'''</td><td>Clears the rules for ALL of the chains</td></tr><tr><td>'''iptables -F CHAIN-NAME'''</td><td>Clears the rules for only the specified CHAIN-NAME (eg. INPUT or OUTPUT)</td></tr></table><br><br>
    # Issue the following command to reset the iptables policy rulesfor the INPUT chain: <b><code><span style="pointer-events: none;cursor: default;color:#3366CC;font-size:1.2em;">iptables -FINPUT</span></code></b>.# Issue the '''iptables -LINPUT''' command to verify that the iptables rules for the INPUT chain have been resetcleared.# Now, issue the command: <b><code><span style="pointer-events: none;cursor: default;color:#3366CC;font-size:1.2em;">iptables -F</span></code></b><br>and then issue the command: <b><code><span style="pointer-events: none;cursor: default;color:#3366CC;font-size:1.2em;">iptables -L</span></code></b> .What do you notice?
13,420
edits