Iptables Packet Flow to local packet ----> mangle prerouting -------> nat prerouting -------> mangle input -------> filter input packet from local source -------> mangle output -------> nat output -------> filter output -------> mangle postrouting -------> nat postrouting refers to packets forwarded locally -------> mangle prerouting -------> nat prerouting -------> mangle forward -------> filter forward -------> mangle postrouting -------> The difference between nat postrouting drop and reject lies in dropping data packets directly with "drop, when dropping data packets, reject sends the sender an error message indicating that the www.2cto.com mangle table is mainly used to change the characteristics of data packets, such as TOS and TTL. nat tables are mainly used for address translation, the filter table is mainly used to filter the connection status of data packets of interest. You can use-m state -- state NEW, ESTABLISHED, RELATED, INVALID to control NEW indicates a NEW package ESTABLISHED indicates the response package RELATED indicates connections other than the primary connection, such as FTP-data, INVALID indicates no connection status or unrecognized connection status, generally discarded