Linux firewall system --Firewalld command overview (purely theoretical)

Firewalld Firewall Command Overview

Command List

Options Explanation
--get-default-zone It shows the connection or interface default LAN
--set-default-zone=\<zone> Setting a default network connection or interface region
--get-active-zones Show all area activated
--get-zone-of-interface=\<interface> Display area specified binding interface
--zone=\<zone> --add-interface=\<interface> For the specified interface binding region
--zone=\<zone> --change-interface=\<interface> Is bound to change the designated area network interface
--zone=\<zone> --remove-interface=\<interface> Remove the binding for the specified area network interface
--query-interface=\<interface> Query region contains an interface
--list-all-zones Show all area and its rules
[--zone=\<zone>] --list-all Show all rules in all designated areas

Service-related command

Options Explanation
[--zone=\<zone>] --list-services Displays the area to allow access to all services
[--zone=\<zone>] --add-service=\<service> Designated areas set up to allow access to a service
[--zone=\<zone>] --remove-service=\<service> Delete the specified area has been set up to allow access to a service
[--zone=\<zone>] --query-service=\<service> Query whether a designated area in a service enabled

And port-related commands

Options Explanation
[--zone=\<zone>] --list-ports Show all port numbers allowed to access the designated area
[--zone=\<zone>] --add-port=\<port> [-\<port>]/\<protocol> [--timeout=\<seconds>] Enabling regional port and protocol combination, optional super time
[--zone=\<zone>] --remove-port=\<port> [-\<port>]/\<protocol> Port and protocol combination a disable area
[--zone=\<zone>] --query-port=\<port>[-\<port>]/\<protocol> Query whether the port area and enable the combination protocol

Block ICMP on command

Options Explanation
[--zone=\<zone>] --list-icmp-blocks Show all ICMP type obstruction within the designated area
[--zone=\<zone>] --add-icmp-block=\<icmptype> Specified locale blocking an ICMP type
[--zone=\<zone>] --remove-icmp-block=\<icmptype> Delete the specified area has blocked an ICMP type
[--zone=\<zone>] --query-icmp-block=\<icmptype> ICMP query blocking feature a designated area

Guess you like

Origin blog.51cto.com/14484404/2444851