Open main menu

CDOT Wiki β

Changes

OPS235 Lab 7 - CentOS7 - HD2

727 bytes added, 16:44, 24 October 2016
no edit summary
# Were there already iptables policy rules that already existed by default?
# Before we proceed, we need to understand various methods to list iptables rules:<br><br>'''Listing iptables Rules:'''<br><table width="100%" cellpadding="10" cellspacing="0" border="1"><tr><td width="30%">'''iptables -L'''</td><td>List all iptables rules (eg. INPUT, OUTPUT. FORWARD, and any customized chains (if any)</td></tr><tr><td>'''iptables -L -v'''</td><td>Verbosely List all iptables rules including information such as total size of packets affected by rules</td></tr><tr><td>'''iptables -L CHAIN-NAME'''</td><td>List all iptables rules for that particular chain-name for less clutter (eg. INPUT or OUTPUT, etc)</td></tr></table><br>
# Issue the following Linux command: <b><code><span style="pointer-events: none;cursor: default;color:#3366CC;font-size:1.2em;">iptables -L INPUT</span></code></b><br>What do you notice is different with this command compared to the previous iptables command?
# 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?
 
 
 
 
# Issue the following command to reset the iptables policy rules: <b><code><span style="pointer-events: none;cursor: default;color:#3366CC;font-size:1.2em;">iptables -F</span></code></b>.
# Issue the '''iptables -L''' command to verify that the iptables rules have been reset.
13,420
edits