大网数据广告活动
服务器运维问答

PFSense IPSec and NAT

· 52CE 我爱测

Due to bad design and hosting provider constraints I have a network where I don't control the router. Our network: 172.16.0.0/12 - LAN x.x.x.0/24 - WAN (Router is connected to the switches, we have no control over it) 192.168.253…

问题原文

原帖链接 · Yoav · CC BY-SA 3.0

Due to bad design and hosting provider constraints I have a network where I don't control the router.

Our network: 172.16.0.0/12 - LAN x.x.x.0/24 - WAN (Router is connected to the switches, we have no control over it) 192.168.253.0/24 - IPSec client network 172.16.0.50/12 - PFsense internal IP x.x.x.251/24 - PFsense internet IP

We're using PFSense 2.2.6.

I have configured IPsec remote access using this guide: https://doc.pfsense.org/index.php/IPsec_Road_Warrior/Mobile_Client_How-To

It works fine as long as I add static route to destination server (ip r add 192.168.253.0/24 via 172.16.0.50). Ofcourse it'll not work in any other situation because my main router isn't familiar with PFsense, or anything in the LAN segment. It only has interface in the WAN subnet.

Is there a way to make my remote clients have IP within the 172.16.0.0/12 subnet once they connect? Can I NAT their traffic from 192.168.253.0/24 to some address at 172.16.0.0/12?

Please see attached diagram. Green side is LAN. I'd like to achieve NAT from the tunnel network (192.168.253.0/24) to LAN (172.16.0.0/12) using LAN IP.

Thanks!

已采纳解答

原帖链接 · Yoav · CC BY-SA 3.0

Found the solution.

Created Outbound NAT rule on the LAN interface. Source is tunnel network, destination is LAN network.

Source IP is always firewall IP, but that's something I can live with.

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2016-04-05)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 3.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。