Question

What command configures the Linux firewall? What firewall rules are currently in place? What command did...

What command configures the Linux firewall?
What firewall rules are currently in place?
What command did you use to list the filewall rules?
What is the difference between drop and reject?
How can you delete a firewall rule?
How can you delete all the firewall rules?

0 0
Add a comment Improve this question Transcribed image text
Answer #1

What command configures the Linux firewall?
sudo iptables -S

What firewall rules are currently in place?
sudo iptables -L INPUT -v

What command did you use to list the filewall rules?
sudo iptables -L

What is the difference between drop and reject?


As a general rule, use REJECT when you want the other end to know the port is unreachable' use DROP for connections to hosts you don't want people to see.

Using DROP makes the connection appear to be to an unoccupied IP address. Scanners may choose not to continue scanning addresses which appear unoccupied. Given that NAT can be used to redirect a connection on the firewall, the existence of a well known service does not necessarily indicate the existence of a server on an address.

When using REJECT rules an ICMP packet is sent indicating the port is unavailable.

How can you delete a firewall rule?
sudo iptables -L --line-numbers
or
sudo iptables -D INPUT 3

How can you delete all the firewall rules?
First, set the default policies for each of the built-in chains to ACCEPT. The main reason to do this is to ensure that you won't be locked out from your server via SSH:

sudo iptables -P INPUT ACCEPT
sudo iptables -P FORWARD ACCEPT
sudo iptables -P OUTPUT ACCEPT

sudo iptables -X

if you have any doubt then please ask me without any hesitation in the comment section below , if you like my answer then please thumbs up for the answer , before giving thumbs down please discuss the question it may possible that we may understand the question different way and we can edit and change the answers if you argue, thanks :)

Add a comment
Know the answer?
Add Answer to:
What command configures the Linux firewall? What firewall rules are currently in place? What command did...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT