Skip to content

Instantly share code, notes, and snippets.

View greymouser's full-sized avatar

Armando Di Cianno greymouser

  • Williamstown, MA
View GitHub Profile
@greymouser
greymouser / blog-ssh-1-1
Created November 17, 2010 16:14
blog-ssh-1-1
$ ssh-keygen -t dsa
Generating public/private dsa key pair.
Enter file in which to save the key (/Users/fafhrd/.ssh/id_dsa): # Hit 'Return', if you have never created a key before, or the path to your new key -- yes, you can have more than 1.
Enter passphrase (empty for no passphrase): # NO! DO NOT HIT ENTER! ENTER A PASSPHRASE!
Please, type in a passphrase
Enter same passphrase again: # And again
@greymouser
greymouser / blog-ssh-1-2
Created November 17, 2010 16:16
blog-ssh-1-2
$ /usr/bin/ssh-add -l
1024 XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX /Users/fafhrd/.ssh/id_dsa (DSA)
@greymouser
greymouser / blog-ssh-1-3
Created November 17, 2010 16:17
blog-ssh-1-3
$ /usr/bin/ssh-add -K ~/.ssh/id_dsa
Enter passphrase for /Users/fafhrd/.ssh/id_dsa:
Identity added: /Users/fafhrd/.ssh/id_dsa (/Users/fafhrd/.ssh/id_dsa)
$ /usr/bin/ssh-add -K ~/.ssh/id_rsa
Enter passphrase for /Users/fafhrd/.ssh/id_rsa:
Identity added: /Users/fafhrd/.ssh/id_rsa (/Users/fafhrd/.ssh/id_rsa)
$ /usr/bin/ssh-add -l
1024 XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX /Users/fafhrd/.ssh/id_dsa (DSA)
2048 XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX /Users/fafhrd/.ssh/id_rsa (RSA)
$ ssh-add -l
2048 XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX /Users/fafhrd/.ssh/id_rsa (RSA)
1024 XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX /Users/fafhrd/.ssh/id_dsa (DSA)
@greymouser
greymouser / blog-ssh-1-5
Created November 17, 2010 16:19
blog-ssh-1-5
$ ssh myname@my.fake.com 'cat >> ~/.ssh/authorized_keys' < ~/.ssh/id_dsa.pub
@greymouser
greymouser / blog-ssh-1-6
Created November 17, 2010 16:20
blog-ssh-1-6
$ ssh myname@my.fake.com "uname -a"
Linux my 2.6.32-24-server #42-Ubuntu SMP Fri Aug 20 15:38:55 UTC 2010 x86_64 GNU/Linux
@greymouser
greymouser / blog-ssh-1-7
Created November 17, 2010 16:49
blog-ssh-1-7
Host *.fake.com
User myname
@greymouser
greymouser / blog-ssh-1-8
Created November 17, 2010 16:50
blog-ssh-1-8
$ ssh my.fake.com "uname -a"
Linux my 2.6.32-24-server #42-Ubuntu SMP Fri Aug 20 15:38:55 UTC 2010 x86_64 GNU/Linux
@greymouser
greymouser / blog-ssh-2-1
Created November 18, 2010 22:04
blog-ssh-2-1
MYDIR="$HOME/Projects/macfuse/repos"
mkdir -p $MYDIR
cd $MYDIR
svn co http://macfuse.googlecode.com/svn/trunk/filesystems/sshfs/binary sshfs-binaries
cd sshfs-binaries
sudo cp sshfs-static-leopard /usr/local/bin/sshfs
@greymouser
greymouser / blog-ssh-2-2
Created November 18, 2010 22:07
blog-ssh-2-2
VOLNAME=myremotehome
SRVNAME=my.fake.com
mkdir -p $HOME/Volumes/$VOLNAME
sshfs $SRVNAME: $HOME/Volumes/$VOLNAME -oauto_cache,reconnect,volname=$VOLNAME
# Did it work?
ls $HOME/Volumes/$VOLNAME
/sbin/umount $HOME/Volumes/$VOLNAME # or drag to eject button from desktop