forked from guillaume.emorine/siotp
		
	Modifié : sisr1/tp07/files_firewall/current_ruleset_partie_5.nft
This commit is contained in:
		| @@ -14,6 +14,7 @@ define ipdmz = 172.16.0.254 | |||||||
| define iplan = 10.0.0.254 | define iplan = 10.0.0.254 | ||||||
|  |  | ||||||
| table ip ipfilter{ | table ip ipfilter{ | ||||||
|  |  | ||||||
| 	chain prerouting { | 	chain prerouting { | ||||||
|                 type filter hook prerouting priority filter; policy drop; |                 type filter hook prerouting priority filter; policy drop; | ||||||
| 		ct state established, related accept | 		ct state established, related accept | ||||||
| @@ -25,8 +26,12 @@ table ip ipfilter{ | |||||||
|                 tcp dport {80, 443} ip saddr $lan-ntw accept |                 tcp dport {80, 443} ip saddr $lan-ntw accept | ||||||
| 		tcp sport {80, 443} ip saddr $lan-ntw accept | 		tcp sport {80, 443} ip saddr $lan-ntw accept | ||||||
| 		tcp dport 22 accept | 		tcp dport 22 accept | ||||||
|  | 		udp sport 53 iif {$dmzif, $lanif} accept | ||||||
|  | 		udp dport 53 accept | ||||||
| 		ip saddr $proxy tcp dport {80, 443} accept | 		ip saddr $proxy tcp dport {80, 443} accept | ||||||
|  | 		ip daddr $dns accept | ||||||
|         } |         } | ||||||
|  |  | ||||||
| 	chain system_in { | 	chain system_in { | ||||||
|                 type filter hook input priority filter; policy drop; |                 type filter hook input priority filter; policy drop; | ||||||
| 		ct state established, related accept | 		ct state established, related accept | ||||||
| @@ -36,8 +41,11 @@ table ip ipfilter{ | |||||||
|                 tcp dport 21 accept |                 tcp dport 21 accept | ||||||
|                 tcp dport {80, 443} accept |                 tcp dport {80, 443} accept | ||||||
|                 tcp dport 22 accept |                 tcp dport 22 accept | ||||||
|  | 		udp sport 53 accept | ||||||
|  |                 udp dport 53 accept | ||||||
| 		ip saddr $proxy tcp dport {80, 443} accept | 		ip saddr $proxy tcp dport {80, 443} accept | ||||||
|         } |         } | ||||||
|  |  | ||||||
|  	chain routing { |  	chain routing { | ||||||
|                 type filter hook forward priority filter; policy drop; |                 type filter hook forward priority filter; policy drop; | ||||||
| 		ct state established, related accept | 		ct state established, related accept | ||||||
| @@ -45,7 +53,11 @@ table ip ipfilter{ | |||||||
| 		icmp type echo-reply iif {$dmzif} oif {$lanif} accept | 		icmp type echo-reply iif {$dmzif} oif {$lanif} accept | ||||||
|                 tcp dport {80, 443} ip saddr $lan-ntw accept |                 tcp dport {80, 443} ip saddr $lan-ntw accept | ||||||
| 		tcp sport {80, 443} ip saddr $lan-ntw accept | 		tcp sport {80, 443} ip saddr $lan-ntw accept | ||||||
|  | 		udp sport 53 iif {$lanif, $dmzif} accept | ||||||
|  | 		udp dport 53 accept | ||||||
|  | 		ip daddr $dns accept | ||||||
| 	} | 	} | ||||||
|  |  | ||||||
|  	chain system_out { |  	chain system_out { | ||||||
|                 type filter hook output priority filter; policy drop; |                 type filter hook output priority filter; policy drop; | ||||||
|                 ip daddr $dns accept |                 ip daddr $dns accept | ||||||
| @@ -59,7 +71,10 @@ table ip ipfilter{ | |||||||
|                 tcp dport {80, 443} accept |                 tcp dport {80, 443} accept | ||||||
| 		tcp sport {80, 443} accept | 		tcp sport {80, 443} accept | ||||||
| 		tcp sport 22 accept | 		tcp sport 22 accept | ||||||
|  |                 udp sport 53 accept | ||||||
|  |                 udp dport 53 accept | ||||||
|         } |         } | ||||||
|  |  | ||||||
| 	chain postrouting { | 	chain postrouting { | ||||||
|                 type filter hook postrouting priority filter; policy drop; |                 type filter hook postrouting priority filter; policy drop; | ||||||
| 		ct state established, related accept | 		ct state established, related accept | ||||||
| @@ -76,6 +91,9 @@ table ip ipfilter{ | |||||||
|                 tcp dport {80, 443} accept |                 tcp dport {80, 443} accept | ||||||
| 		tcp sport {80, 443} accept | 		tcp sport {80, 443} accept | ||||||
| 		tcp sport 22 accept | 		tcp sport 22 accept | ||||||
|  |                 udp sport 53 accept | ||||||
|  |                 udp dport 53 accept | ||||||
|  | 		ip daddr $dns accept | ||||||
| 	} | 	} | ||||||
|  |  | ||||||
| 	chain pre_nat { | 	chain pre_nat { | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user