Lewatkan ke konten utama

Membuat Akses VPN dengan L2TP/IPsec

Kami akan memberikan panduan untuk membuat akses VPN dari jaringan internet rumah/kantor (indihome). Akses user menggunakan VPN Windows 11.

1. Buat IP pool untuk klien VPN

/ip pool add name=pool-vpn ranges=192.168.89.10-192.168.89.250

2. Buat profile PPP untuk L2TP

/ppp profile add name=profile-vpn local-address=192.168.89.1 dns-server=8.8.8.8 remote-address=pool-vpn use-encryption=yes

3. Tambah user (secret)

/ppp secret add name=opd1 password=Dishub2025! service=l2tp profile=profile-vpn

4. Aktifkan L2TP server

/interface l2tp-server server set enabled=yes authentication=mschap2 default-profile=profile-vpn use-ipsec=required ipsec-secret=Kominfo-Hebat2025! max-mtu=1460 max-mru=1460

5. Konfigurasi IPsec (policy/proposal)

/ip ipsec proposal set [find default=yes] auth-algorithms=sha1 enc-algorithms=aes-128-cbc,aes-256-cbc pfs-group=none

6. Firewall: izinkan paket IPsec & L2TP (UDP 500, UDP 1701, UDP 4500, ESP)

/ip firewall filter add chain=input protocol=udp dst-port=500,1701,4500 action=accept comment="Allow IPsec/L2TP UDP"
# Allow ESP (protocol 50)
 /ip firewall filter add chain=input protocol=ipsec-esp action=accept comment="Allow ESP"
# Allow established/related (biasanya sudah ada)

7. NAT: masquerade agar client bisa akses internet melalui router

/ip firewall nat add chain=srcnat src-address=192.168.89.0/24 out-interface=<WAN-INTERFACE-NAME> action=masquerade comment="NAT VPN clients"

8.