Install Vtun On FreeBSD

TUN/TAP provides packet reception and transmission for user space programs.
It can be viewed as a simple Point-to-Point or Ethernet device, which
instead of receiving packets from a physical media, receives them from
user space program and instead of sending packets via physical media
writes them to the user space program.

When a program opens /dev/tunX or /dev/tapX, driver creates and
registers corresponding net device tunX or tapX. After a program closed
above devices, driver will automatically delete tunXX or tapXX device
and all routes corresponding to it.

Install


cd /usr/ports/net/vtun

make install

config /usr/local/etc/vtun.conf

examples :

freebsd {
passwd freebsd;
type ether;
device tap1;
proto tcp;
compress lzo:9;
encrypt yes;
up {
ifconfig “%% inet 172.21.21.2 netmask 255.255.255.252 up”;
#
route “add -net 10.xx.x.0/26 172.21.21.1”;
route “add -net 0.xx.x.0/26 172.21.21.1”;
#
firewall “reload”;
};
down { ifconfig “%% delete”; firewall “reload”; };
multi killold;
}

starting vtun
/usr/local/sbin/vtund -f /usr/local/etc/vtund.conf freebsd <IP Address>

cek pada ifconfig, jika pesan error “failed to allocate tap device

ketik pada console

kldload if_tap

cek ifconfig kembali…

Autosart vtun server Reboot

pico /etc/rc.local

#ADD TAP VTUN
kldload if_tap

#Autosart http-accept filter  Nginx proxy
echo && echo -n “Loading HTTP/HTTPS Accept filter modules.” && /sbin/kldload accf_http && /sbin/kldload accf_data
echo

##Autostart vtun
/usr/local/sbin/vtund -f /usr/local/etc/vtund.conf freebsd <IP Address>

 

 

Posted on: October 18, 2017, by :  | 44 views

Leave a Reply

https://serang.ut.ac.id/css/css/slot88/ https://tinjut.bagkeu.dikdasmen.kemdikbud.go.id/slot-maxwin/ https://dpm.polinema.ac.id/slot-gacor/ https://akademik.ft.unm.ac.id/slot-dana/ https://ppdb.probolinggokab.go.id/slot-5000/ https://bkad.sulselprov.go.id/assets/ https://ojs.balidwipa.ac.id/docs/slot-gacor/ http://korpri.pekalongankab.go.id/api/slot-gacor/ https://elang.umpp.ac.id/foto/farmasi/-/asset/ http://rsud-kelet.jatengprov.go.id/wp-content/-/asset/ https://kusdhianto-fe.staff.ugm.ac.id/slot88/ http://ppdb.probolinggokab.go.id/judi-bola/ https://bapenda.labuhanbatukab.go.id/racikan-sbobet/ http://rsud-kelet.jatengprov.go.id/wp-content/-/data/ https://agenda.riau.go.id/-/judi-bola/ https://balapan.padang.go.id/sbobet88/ http://jdih.wakatobikab.go.id/sbobet88/ http://kph.menlhk.go.id/sbobet88/ https://bkad.sulselprov.go.id/data/ https://dpm.polinema.ac.id/slot-gacor/ https://dinkes.jemberkab.go.id/storage/attachments/