Connect to office vpn using speedy + linksys DD-WRT

Sometimes, i need to access to my computers/servers at office Local Area Network from home. i used to dialed vpn connection from windows XP home.but here, i'll share how to automatically connect to vpn server via linksys dd-wrt pptp client.

  • Connect to linksys/dd-wrt management via browser, point it to http://192.168.1.1 (default ip management)
  • Login and go to Services -> PPTP tab -> PPTP Client section

speedy linksys dd-wrt vpn pptp

  • Adjust Server IP or DNS Name, Remote Subnet, Remote Subnet Mask User and Password according to your network configuration.

Securing MySQL traffic with stunnel

To encrypt a connection between a mysql client and a mysql server, run two instances of stunnel, one on client site and other on MySQL remote site

Here’s steps how to do it

# wget http://www.stunnel.org/download/stunnel/src/stunnel-4.27.tar.gz
# rpmbuild -ta stunnel-4.27.tar.gz
# rpm -ivh /usr/src/redhat/RPMS/stunnel-4.27-1.i386.rpm

Create stunnel.pem cert on server site

# openssl genrsa -out privkey.pem 2048
# openssl req -new -x509 -key privkey.pem -out cacert.pem -days 1095
# cat privkey.pem cacert.pem >> /etc/stunnel/stunnel.pem

Set the proper permissions on the resulting private key:

# chmod 0400 /etc/stunnel/stunnel.pem

Set the proper ownership of the stunnel chroot dir

# chown nobody:nobody /var/run/stunnel

centos 5 point to point tunneling PPTP VPN

Pernah terpikir buat ngeremote pc di kantor(dengan private ip) dari rumah dengan koneksi isp yg kita pakai?   salah satunya dengapn cara tunneling/vpn. kali yg jadi korban kita distro centos 5 dengan kernel 2.6.18-92.1.13.el5. gimana cara installnya?

pertama install yum repository nya

# rpm -Uvh http://pptpclient.sourceforge.net/yum/stable/fc6/pptp-release-current.noarch.rpm

lanjut dengan install pptpnya

# yum --enablerepo=pptp-stable install pptp

HOWTO VPN over SSH and tun

Do it with a Script

Introduction

The following script will let you start a full featured VPN using SSH and tun.
Requirements

* OpenSSH with tun support on both sides (tested Debian 4.3 on server, Gentoo 4.5 on client)
* Root access on both sides * Allowed root access and tunnel on server side:

File: /etc/ssh/sshd_config

PermitRootLogin yes
PermitTunnel yes
TCPKeepAlive yes # Not required but makes things much more stable. This is default now
* Compiled ‘tun’ module on both sides
* Loaded ‘tun’ module on server side 
* Allowed ARP proxy (required only for accessing client from within the private network)