I managed to complie the tun.ko kernel module which can be used for openvpn software. I used the San Frans kernel from ZTE site.
it works with 2.1 Eclair ONLY, I would need the 2.2 kernel source to be able to compile it to Froyo.
Compilation was according to this guide:
http://android.modac...r-for-htc-hero/
Usage (phone should be rooted):
1) Copy the tun.ko to /system/lib/modules/ using Root Explorer or by adb + R+W remounting (http://android.modac.../322750/system/)
2) use "OpenVPN Installer" to install the openvpn binary:
- Appbrain link: http://www.appbrain....envpn.installer
- start OpenVPN installer
- select /system/xbin for target loaction of openVPN binary
- select /system/xbin/bb for location of ifconfig and route commands. None of the other locations was working for me. (The location of ifconfig and route is crutial because busybox should be used otherwise the ifconfig and route commands pushed by server will fail with "invalid argument". /system/xbin does not work for some reason even if /system/xbin/bb is a simlink to it).
- after installation you can remove the OpenVPN installer, the binary openvpn from /system/xbin will not be removed during uninstallation
3) Create openvpn folder on SDCARD and put the configuration there (configfile.ovpn, certificates etc)
4) install openVPN Setting from AppBrain: http://www.appbrain....android.openvpn.
Launch openVPN Settings and go to Advanced menu
- Load tun kernel module: yes
- TUN module settings:
- Load module using: insmod
- Path to tun module: /system/lib/modules/tun.ko
- path to configurations: /sdcard/openvpn
- path to openvpn binary: /system/xbin/openvpn
- Fix HTC Routes: no
- Show ads: yes/no
5) at this point the program will read the /sdcard/openvpn/ and you should see the profile, maybe restart of "OpenVPN Settings" is needed
6) you can longpress on the .opvn config to set extra DNS parameter, I did not chnage those.
Issues:
- OpenVPN settings starts automatically on boot. Use some startup disabler.
- FROYO users: in Paul's 2.2 ROM the /system/xbin/bb symlink does not exist and the /system/xbin does not contain the busybox links. So if in your ROM the /system/xbin/bb/ directory does not exist you have to create it and add the necessery symlinks:
adb shell mkdir /system/xbin/bb
adb shell ln -s /system/bin/busybox /system/xbin/bb/ifconfig
adb shell ln -s /system/bin/busybox /system/xbin/bb/route
I've also complied CIFS/SAMBA module, that aslo works using the standard mount -t cifs... command. Put it to the /system/lib/modules/ and load it with "insmod /system/lib/modules/cifs.ko". Note: CIFS is not required for OpenVPN.
(sudo mount -t cifs //netbiosname/sharename /media/sharename -o username=winusername,password=winpassword)
Note: I'm not an expert of OpenVPN so I just compiled the module and it just works for me.
Attached Files
Edited by pbando, 10 January 2011 - 01:33 PM.






Sign In
Create Account


Back to top










