2019-01-07 22:48:42 +00:00
|
|
|
#! /sbin/nft -f
|
|
|
|
|
2019-02-09 09:23:05 +00:00
|
|
|
table ip nat {
|
2019-01-07 22:48:42 +00:00
|
|
|
chain prerouting {
|
|
|
|
type nat hook prerouting priority 0;
|
2019-02-09 09:23:05 +00:00
|
|
|
meta iifname $if_prerezotage ip daddr != { $intranet, $comnpay, $website } tcp dport {http,https} dnat $bounce_server;
|
2019-01-07 22:48:42 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
chain postrouting {
|
|
|
|
type nat hook postrouting priority 100
|
2019-02-09 09:23:05 +00:00
|
|
|
|
|
|
|
meta oifname != $if_supelec return
|
|
|
|
|
|
|
|
meta iifname vmap {
|
|
|
|
$if_adherent : goto adh_nat,
|
|
|
|
$if_admin : goto adm_nat,
|
|
|
|
$if_aloes : goto aloes_nat,
|
|
|
|
$if_federez : goto federez_nat,
|
|
|
|
$if_prerezotage : goto prerezotage_nat,
|
|
|
|
}
|
|
|
|
|
2019-01-08 23:21:24 +00:00
|
|
|
ip saddr 10.0.0.0/8 masquerade
|
2019-01-07 22:48:42 +00:00
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|