Skip to main content

Ubuntu how to setup a vpn connection, tsocks, corporate wifi with openconnect and openvpn or socks

These are just notes.

Cisco vpn setup [corporate setup]


# install
sudo apt-get install openconnect network-manager-openconnect-gnome

VPN GUI setup
# select dynamic updates
sudo dpkg-reconfigure resolvconf


#restart network-manager or reboot the laptop


#  create a new VPN openconnect connection, set only the gateway
nm-connection-editor

Gnome network manager GUI configuration

[This is not needed for Ubuntu 15.04 and 16.10]. The default routing rules are missing in ubuntu openconnect 15.10/16.04. After the network manager establishes the connection, the work around is to add a default route as specified below after the connection is established. Start a console and type the command below with the correct arguments.

sudo route add default netmask 255.255.255.0 gw 10.87.154.223 dev vpn0

run ifconfig to figure out the vpn device name, the gateway ip of the vpn device normally tun0 or vpn0.

Execute the command above and the default route should make the openconnect vpn work.

Command line without network manager

# open a connection, use --background to run as daemon
sudo openconnect --user=USERID server/group/

# to stop the connection you can ctrl-c the terminal running openconnect or

sudo killall openconnect*

Setup openvpn using ibvpn.com provider and openvpn

sudo apt-get install openvpn easy-rsa network-manager-openvpn-gnome

goto http://www.ibvpn.com

setup a free account

extract openvpn.tgz where you want

On UbuntuGnome goto settings->network->add
select vpn->Import from file

Select ibVPN-US-Dallas.ovpn


Type your email
Get the password from the ibvpn website, this is not you ibvpn account password.




Select Add.
And try it out.

Using  a socks proxy instead of VPN


# run a local socks server
ssh -D 9999 proxy.server

# setweb browser proxy or gnome network proxy in gnome network settings.
proxy: localhost:9999

# To use other apps with socks install
sudo apt-get install tsocks

# Change config file to (remove everything else)
/etc/tsocks.conf
server = 127.0.0.1
server_port = 9999

# ssh to a machine
tsocks ssh -X bla.corp.com

# eclipse to a machine
tsocks eclipse

Comments

Popular posts from this blog

Ubuntu 17.10 running on Lenovo Yoga 920 with HiDPI and touch screen support

I resized the windows partiton to the minimun necessary (100G), disabled secure boot and I also remove bitlocker key encryption on windows drive, this allows Ubuntu to see that partition and allow windows to boot with secure boot disabled, without complaning.

This makes everything go easier if you want to keep windows arround on the same disk and dual boot with Ubuntu, you should do this it helps a lot. Even after you disable this, you can re-enable it back, both secure boot and bitlocker key encryption.

Before installing on windows updates resize your windows partition, installing all windows updates will not alow you to gain as much space as possible. After resizing the windows partition to the minimium size you want, install all windows updates, bios and driver updates.

I upgraded all windows updates to the latest version and all drivers to the latest version and upgraded the bios on windows to the latest version before installing Ubuntu, I don't think this makes much differenc…

Chrome OS advanced commands, settings, expert features

Chrome OS advanced commands, settings, expert features All features described here where tested on a Asus C302 Chromebook, but should work on all Chromebooks, screenshots are from the Asus C302.
Recovery Install new factory image for your chrome book
https://support.google.com/chromebook/answer/1080595?hl=en

Perform a Hard Reset Go to settings select the reset section, you can do a reset or a powerwash.

Force-Boot Into Recovery Mode If you’d like to reinstall Chrome OS and you don’t see the “Chrome OS is missing or damaged” message on your screen, you can force your Chromebook to boot into recovery mode.

First, turn off your Chromebook. Next, press Esc + Refresh on the keyboard and hold down the Power button. Your Chromebook will boot straight to recovery mode.

Enable Canary First, turn off your Chromebook. Press Esc+Refresh+Power and, when the recovery prompt appears, press Ctrl+D and accept the prompt that appears to disable boot verification. When the Chromebook reboots, press Ctrl…

Ubuntu GNOME 17.04 running with HiDPI and touch screen support

Ubuntu GNOME 17.04 running with HiDPI and touch screen support








See my previous post on how to install Ubuntu on Yoga Pro 2 for Ubuntu GNOME 16.10.

I think Ubuntu GNOME is the best flavor of Ubuntu if you are running in HiDPI mode 3200x1800. All screen captured images are at HiDPI resolution.
Touch support Ubuntu gnome support for touch screen is pretty good on the desktop shell.
Chrome browser supports touch screen very well and much better than Firefox without any plug-ins.
The windows key on the screen panel works as the windows key on the keyboard.
Screen rotation is supported on the new gnome and disables the keyboard when the yoga is used as a tablet, side lock rotation button works to lock the screen in a certain rotation.



 What works Almost everything works great out of the box, there isn't many changes you need to do.
UbuntuGnome ships with gnome 3.24 and will boot with full resolution HiDPI and touch screen support enabled
Screen HiDPI supportBrightness, resolution keys, o…