Saturday 4 January 2014

Konfigurasi VPN PPTP di Mikrotik

Virtual Private Network (VPN)

VPN dalah sebuah jaringan komputer dimana koneksi antar perangkatnya (node) memanfaatkan jaringan public sehingga yang diperlukan hanyalah koneksi internet di masing-masing site.
Ketika mengimplementasikan VPN, interkoneksi antar node akan memiliki jalur virtual khusus di atas jaringan public yang sifatnya independen. Metode ini biasanya digunakan untuk membuat komunikasi yang bersifat secure, seperti system ticketing online dengan database server terpusat.

Point to Point Tunnel Protocol (PPTP)
Salah satu service yang biasa digunakan untuk membangun sebuah jaringan VPN adalah Point to Point Tunnel Protocol (PPTP). Sebuah koneksi PPTP terdiri dari Server dan Client.
Mikrotik RouterOS bisa difungsikan baik sebagai server maupun client atau bahkan diaktifkan keduanya bersama dalam satu mesin yang sama. Feature ini sudah termasuk dalam package PPP sehingga anda perlu cek di menu system package apakah paket tersebut sudah ada di router atau belum. Fungsi PPTP Client juga sudah ada di hampir semua OS, sehingga kita bisa menggunakan Laptop/PC sebagai PPTP Client.
Biasanya PPTP ini digunakan untuk jaringan yang sudah melewati multihop router (Routed Network). Jika anda ingin menggunakan PPTP pastikan di Router anda tidak ada rule yang melakukan blocking terhadap protocol TCP 1723 dan IP Protocol 47/GRE karena service PPTP menggunakan protocol tersebut.
Topologi
Pada artikel ini akan dicontohkan apabila kita akan menghubungkan jaringan dengan menerapkan VPN dengan PPTP. Untuk topologi nya bisa dilihat pada gambar di bawah.
PPTP rev1 Konfigurasi VPN PPTP di Mikrotik
Router Office A dan Router Office B terhubung ke internet via ether 1 dan PC pada masing-masing jaringan lokal terhubung ke Ether 2. Remote client juga sudah terhubung ke internet.
Kita akan melakukan konfigurasi agar Router A dan jaringan LAN A bisa diakses dari Router B dan
jaringan LAN B serta Remote Client. Langkah-langkah setting PPTP dengan Winbox sebagai berikut:
Konfigurasi PPTP Server
Berdasar topologi di atas, yang menjadi pusat dari link PPTP (konsentrator) adalah Router Office A , maka kita harus melakukan setting PPTP Server pada router tersebut.
Enable PPTP Server
Langkah pertama yang harus dilakukan adalah mengaktifkan PPTP server. Masuk pada menu PPP->Interface->PPTP Server . Gunakan profile “Default-encryption” agar jalur VPN terenkripsi.
Server.0.1 Konfigurasi VPN PPTP di Mikrotik
Secret
Pada tahap ini, kita bisa menentukan username dan password untuk proses autentikasi Client yang akan terkoneksi ke PPTP server. Penggunaan huruf besar dan kecil akan berpengaruh.
-Local Address adalah alamat IP yang akan terpasang pada router itu sendiri (Router A / PPTP Server) setelah link PPTP terbentuk
-Remote Address adalah
alamat IP yang akan diberikan ke Client setelah link PPTP terbentuk.
Contoh konfigurasi sebagai berikut. Arahkan agar menggunakan profile “Default-Encryption”
Secret.rev.0.1 Konfigurasi VPN PPTP di Mikrotik
Sampai disini, konfigurasi Router A (PPTP Server) sudah selesai, sekarang kita lakukan konfigurasi di sisi client.
Client Router Office B
Langkah-langkah untuk melakukan konfigurasi Client PPTP pada Router Mikrotik adalah sebagai berikut :
Tambahkan interface baru PPTP Client, lakukan dial ke IP Public Router A (PPTP server) dan masukkan username dan password sesuai pengaturan secret PPTP Server.
client.router.0.1 Konfigurasi VPN PPTP di Mikrotik
Catatan : IP 10.10.10.100 adalah permisalan ip public dari server, Untuk implementasi sebenarnya sesuaikan dengan ip public yang Anda miliki.
Setelah koneksi PPTP terbentuk, akan muncul IP Address baru di kedua Router dengan flag “D” yang menempel di interface pptp sesuai dengan pengaturan Secret pada PPTP server
Sampai disini koneksi VPN antar router sudah terbentuk, akan tetapi antar jaringan lokal belum bisa saling berkomunikasi. Agar antar jaringan local bisa saling berkomunikasi, kita perlu menambahkan routing static dengan konfigurasi
dst-address : jaringan local Router lawan
gateway : IP PPTP Tunnel pada kedua router.
routing routera Konfigurasi VPN PPTP di Mikrotik
Penambahan static route di Router A
Routing B Konfigurasi VPN PPTP di Mikrotik
Penambahan static route di router B
 
Remote Client 
Client PPTP tidak harus menggunakan Router. Seperti pada topologi jaringan di atas, ada sebuah Remote Client (Laptop) yang akan melakukan koneksi VPN ke Router A.
Maka kita perlu membuat Secret baru pada PPTP server untuk autentikasi remote client tersebut.
Secret
username = client2 ; password = 1234 ; Local Address = 10.20.20.1 ; Remote Address = 10.20.20.7
Secret.rev.0.2 Konfigurasi VPN PPTP di Mikrotik
Kemudian kita perlu melakukan konfigurasi PPTP Client pada Laptop. Langkah-langkahnya akan berbeda pada tiap OS. Berikut  tutorial konfigurasi PPTP Client untuk OS Windows 7.
Konfigurasi PPTP Client Windows 7
Pastikan Laptop anda sudah bisa akses internet. Masuk pada menu Network and Sharing Center, kemudian create koneksi baru dengan memilih Set up new connection or network.
Client Laptop.1.1 Konfigurasi VPN PPTP di Mikrotik
Pada tampilan window selanjutnya, pilih Connect to a workplace , lalu klik next.
Client Laptop.1.2 Konfigurasi VPN PPTP di Mikrotik
Kemudian, pilih Use My Internet Connection (VPN)
Client Laptop.1.3 Konfigurasi VPN PPTP di Mikrotik
Pada langkah berikutnya, kita diminta untuk memasukkan ke IP Address mana kita akan melakukan koneksi. Sesuai topologi , maka kita masukkan IP address public Router A. Destination name adalah parameter untuk memberikan nama pada interface VPN yang sedang dibuat.
Client Laptop.1.4 Konfigurasi VPN PPTP di Mikrotik
Selanjutnya masukkan username dan password sesuai pengaturan Secret yang ada di PPTP server.
Lalu klik Connect.
client.leptop. Konfigurasi VPN PPTP di Mikrotik
Akan ada proses autentikasi, tunggu sampai selesai.
Client Laptop.1.6 Konfigurasi VPN PPTP di Mikrotik
Jika sudah selesai, di laptop akan muncul interface baru dengan nama VPN Office A dan terpasang IP address yang mengambil dari ip-pool Remote Address sesuai dengan pengaturan profile dan Secret pada PPTP Server.
Sampai disini koneksi VPN dari Laptop ke Router A sudah terbentuk.  Laptop sudah bisa akses ke Router A dan Jaringan LAN A.
Untuk melakukan remote ke Router A tinggal anda masukkan IP addres Router yang terpasang setelah link VPN terbentuk, yaitu IP address 10.20.20.1.
Tips :
  • Jalur VPN akan stabil dan lebih mudah dalam konfigurasi apabila sisi server memiliki jalur internet dedicated dan memiliki IP Publik static.
  • Transfer file antar site akan mengikuti bandwidth terkecil dari kedua site, jadi pastikan bandwidth upload dan download di kedua sisi site mencukupi
  • Untuk perangkat client yang menggunakan OS Windows 7, by default hanya bisa terkoneksi apabila disisi server mengaktifkan encryption
Virtual Private Network ( VPN )
VPN refers to a computer network in which the connections between the devices ( nodes ) utilize public etworks so that all you need is an internet connection at each site .
When implementing a VPN , the interconnection between nodes will have a special virtual path over public networks that are independent . This method is usually used to create communication that is secure , such as online ticketing system with a centralized database server .
Point to Point Tunnel Protocol ( PPTP )
One service that is used to establish a VPN network is a Point to Point Tunnel Protocol ( PPTP ) . A PPTP connection consists of a Server and a Client .
RouterOS can function as both a server and a client or even switched the two together in a same machine . This feature is included in the PPP package so you need to check in the menu system package whether the package is already on the router or not . PPTP Client functions also exist in almost all OS , so we can use the Laptop / PC as a PPTP Client .
PPTP is typically used for networks that have passed multihop router ( Routed Network ) . If you want to use PPTP sure in your router no rule that do the blocking of TCP protocol and IP protocol 47/GRE 1723 for PPTP service using the protocol .
topology
In this article we will be exemplified when connecting to the network by implementing a PPTP VPN . For its topology can be seen in the picture below .
PPTP rev1 Konfigurasi VPN PPTP di Mikrotik
Office Router A and Router B are connected to the Internet Office via ether 1 and PC on each local network is connected to the Ether 2 . Remote client also been connected to the internet .
We are going to configure that router A and A LAN network can be accessed from the Router B and
LAN B and Remote Client . PPTP setting steps with Winbox as follows :
Configuring PPTP Server
Based on the topology , which became the center of the link PPTP ( concentrator ) is the Office Router A , then we must do the PPTP server settings on the router .
Enable PPTP Server
The first step to do is to enable the PPTP server . Enter the PPP menu – > Interface – > PPTP Server . Use profile ” default – encryption ” so that encrypted VPN path .
Server.0.1 Konfigurasi VPN PPTP di Mikrotik
Secret.rev.0.1 Konfigurasi VPN PPTP di Mikrotik

No comments:

Post a Comment