reseaux_iptables
Différences
Ci-dessous, les différences entre deux révisions de la page.
Les deux révisions précédentesRévision précédente | Prochaine révisionLes deux révisions suivantes | ||
reseaux_iptables [2010/07/17 11:00] – thierry | reseaux_iptables [2010/07/17 11:00] – thierry | ||
---|---|---|---|
Ligne 39: | Ligne 39: | ||
# interface a autoriser | # interface a autoriser | ||
@def $LAN_IF = eth0 | @def $LAN_IF = eth0 | ||
+ | | ||
# Politique par defaut: tout fermer | # Politique par defaut: tout fermer | ||
chain ( INPUT OUTPUT FORWARD ) policy DROP; | chain ( INPUT OUTPUT FORWARD ) policy DROP; | ||
+ | | ||
# autoriser l' | # autoriser l' | ||
chain INPUT if lo ACCEPT; | chain INPUT if lo ACCEPT; | ||
chain OUTPUT of lo ACCEPT; | chain OUTPUT of lo ACCEPT; | ||
+ | | ||
# autoriser quelques entrées | # autoriser quelques entrées | ||
chain INPUT if $LAN_IF mod state state ( NEW ESTABLISHED RELATED ) { | chain INPUT if $LAN_IF mod state state ( NEW ESTABLISHED RELATED ) { | ||
Ligne 53: | Ligne 53: | ||
proto icmp icmp-type echo-request ACCEPT; | proto icmp icmp-type echo-request ACCEPT; | ||
} | } | ||
- | | + | |
# autoriser toutes les sorties | # autoriser toutes les sorties | ||
chain OUTPUT of $LAN_IF mod state state ( NEW ESTABLISHED RELATED ) ACCEPT; | chain OUTPUT of $LAN_IF mod state state ( NEW ESTABLISHED RELATED ) ACCEPT; |
reseaux_iptables.txt · Dernière modification : 2010/07/17 11:16 de thierry