Tunnel Traffic Proxy

Want to use your local machine firefox browser but want to tunnel your traffic thru your server. Here is how its done using ssh.
$ ssh -D 1080 username@server

additional reading
http://www.redpill-linpro.com/sysadvent//2015/12/13/socks-proxy-as-poor-mans-vpn.html
https://news.ycombinator.com/item?id=10726158
https://github.com/apenwarr/sshuttle

Firefox extension Proxy Switcher

Useful linux application that does similar action without all the browser configuration
https://github.com/apenwarr/sshuttle
$ sshuttle -r username@sshserver 0/0

Git on Windows passwordless with plink

Manual way:

Use Git on Windows with a private key by using pagent, putty and plink

Or the automatic way:

When installing “git on windows” on the “Choosing the SSH executable” screen choose “Use (Tortoise)Plink” and browse for plink.exe.

stackoverflow answer

If you see the below message and it freezes the way to fix it is to open putty, type in the host name (like bitbucket.org), click open, click yes in the popup to cache the host key then close putty

The server's host key is not cached in the registry. You
have no guarantee that the server is the computer you
think it is.
The server's rsa2 key fingerprint is:
ssh-rsa 2048 24:5e:d9:30:a7:96:92:f5:f1:f1:ff
If you trust this host, enter "y" to add the key to
PuTTY's cache and carry on connecting.
If you want to carry on connecting just once, without
adding the key to the cache, enter "n".
If you do not trust this host, press Return to abandon the
connection.
Store key in cache? (y/n) y

Notes:
pageant needs to be running and loged in with private key
windows

tags:
git windows ssh private key

ssh timeout

Working with putty and winscp these programs would timeout/freezes and have to reconnect. Here is how I fixed it.

On the server, have a look in /etc/ssh/sshd_config and see if you have these variables set. If not, add them:

TCPKeepAlive yes
ClientAliveInterval 190

Or on the client edit ~/.ssh/config and add this line

ServerAliveInterval 60

In putty setup under category Connection there is “Seconds between keepalives” option. It was “0” and I changed to 90.

The same option is also in WINSCP program.
winscp keepalive

resource:
http://ubuntuforums.org/archive/index.php/t-1100454.html

ssh without password

SSH Without Authentication Using Key Files
Unix to Unix

Password-less ssh login with Putty and Pageant
Windows to Unix

The key that goes in the server is ssh-rsa


The github version
https://help.github.com/articles/generating-ssh-keys

tags:
ssh without password putty
SSH login with no password

>Passwordless SSH login Tutorial


http://www.howtoforge.com/ssh_key_based_logins_putty

>Passwordless SSH login Tutorial

>$ ssh-keygen -t rsa

Generating public/private rsa key pair.
Enter file in which to save the key (/home/bigbang/.ssh/id_rsa):
(Enter)
Enter passphrase (empty for no passphrase):
(Enter)
Enter same passphrase again:
(Enter)

# this creates a file ~/.ssh/authorized_keys
$ ssh-copy-id user@192.168.1.217
user@192.168.1.217’s password:
(Enter Password)

Now test login in via ssh. It will not ask for the password

ssh without password