However, it is still possible to install the openvpn binary per hand... and it is not as complicated as it seems! This guide only works on rooted devices and is written for Linux users, however the lower part should also work on Windows and Mac.
At first you need to get the Android Debug Bridge binary and install it on your computer (I just put it into $HOME/bin).
Then download the latest OpenVPN Installer APK - we need to extract the openvpn binary from this package:
wget http://android-openvpn-installer.googlecode.com/files/OpenVPN-Installer-0.2.4.apkTo extract the xbin-binary, you can use FileRoller on Gnome or any other tool. Here is an example of how do it with the terminal only:
unzip OpenVPN-Installer-0.2.4.apk assets/openvpn-2.1.1-static-xbinNow use adb to push the binary to your phone/tablet's "sdcard" (external storage):
mv assets/openvpn-2.1.1-static-xbin openvpn
rm -r assets
adb push openvpn /sdcard/The next two commands will open a shell and give us root access on your Android device. Everything you type afterwards happens directly on your device, so be careful!
adb shellNow we need to mount /system as writeable to be able to make changes. Next we copy the binary to its final location and delete it on the sdcard (unfortunately moving is not possible). After we changed the file-permissions so that the binary can be executed, we need to mount /system as read-only again:
su
mount -o remount rw /systemEverything should be done now. Close the connection to your device by typing exit two times and try to use OpenVPN Settings! The installer app will also show you "Binary installed" if everything worked!
cp /sdcard/openvpn /system/xbin/
rm /sdcard/openvpn
chmod 755 /system/xbin/openvpn
mount -o remount ro /system
if you get a error during connecting that ifconfig cannot be executed.
ReplyDeletebefore you remount system ro you need to make a symlink for ifconfig to busybox. the openvpn binary seems to want it in /system/xbin but busybox seems for forget the symlink (but managed to do /system/bin/toolbox *shrug*).
ln -s /system/xbin/busybox ifconfig
and it works.
Thanks for the howto! It helped me until I found a workaround for the OpenVPN Installer App itself, as it is open-source, here is the fix to make it work on Android 4.3:
ReplyDeletehttp://code.google.com/p/android-openvpn-installer/issues/detail?id=23
Should you get a error during connecting that ifconfig can't be executed.
ReplyDeleteBefore you remount system ro you have to make a symlink for ifconfig in order to busybox. the openvpn binary appears to want it in /system/xbin but busybox seems for your investment symlink (but managed to perform /system/bin/toolbox *shrug*.
See more, Tour2Chernobyl
I used ssh (not ADB) to copy openvpn from pc (Debian+ssh) to smartphone (ssh droid), it is the same and it work! :)
ReplyDeleteThank you for this article, it is very helpful!!!
Props! Great How-To.
ReplyDeleteThe easiest way to get the 'openvpn' binary is to download the apk by clicking the link you provided and simply rename the file extension to .zip. Most file browsers can handle this natively.
Anyone else having issues with the openvpn binary on android 4.4?
ReplyDeletefor all you that have problem on android 4.4 use this openvpn installer. off course first uninstall any other version that you may have
ReplyDeletehttp://android-openvpn-installer.googlecode.com/issues/attachment?aid=230007000&name=android-openvpn-installer-use_su_for_proc_mounts-fixed.patch&token=-BgBqaHCaDMcP7TDvHsJoLw42pk%3A1387359913578
sorry this is correct link http://android-openvpn-installer.googlecode.com/issues/attachment?aid=230010000&name=OpenVPNInstaller-debug.apk&token=nSlxvyZmWStEHns82ncwgvrOvkk%3A1387359913579
DeleteDear author, thank you very much. Works perfectly on Google Nexus 7 2013 with latest official (rooted) rom. You saved me lot of time. :)
ReplyDeleteJoe
Thanks :) This made my day ;)
ReplyDeleteHi,
ReplyDeletenice, articel. I run over and over again trough your tutorial after fresh install android rom or get new phone and even help friends. So great job dude!
Regards,
Ivan
on android 5.0.1 it's not working and if i try to launch
ReplyDeleteroot@hammerhead:/system/xbin # openvpn
error: only position independent executables (PIE) are supported.
did you find a fix for it?
Deletegetting the same :-/
Deletehttp://forum.xda-developers.com/sprint-galaxy-s5/help/openvpn-binary-lollipop-s5-t3086672#post64696367
Deleteam using waselpro vpn service for my android device , it's very secured and fast
ReplyDeletehttp://www.openvpnandroid.com/openvpn-for-android/
This comment has been removed by the author.
ReplyDeleteHello i've a Problem to make a VPN Connection (Android 4.4.4) when the file ip is not located in the folder /sbin. Actually it's in the Folder /system/bin
ReplyDeleteThe Problem is when i copy the file in the Folder /sbin it would be removed from System after a Reboot. How i can solve this problem?
Have solved the problem. Installed another VPN App. This works now :)
DeleteHi I really appreciate your all efforts which is specially for the stock.
ReplyDeletewell done.
stock recommendations
Your blog is awesome. You have shared very valuable information to us. Thank you so much for sharing this.
ReplyDeleteconnect vpn
Follow the links on the first page of results for the search terms you're interested in optimizing for. sell backlinks
ReplyDelete