2 \frametitle{Public key authentication
}
5 Mogelijk geen wachtwoord en veiliger
8 \begin{block
}{Command line vlag
}
9 \lstinline{ssh -i ~/.ssh/keyfile frobnicator@foobarbaz.com
}
12 \begin{block
}{Config file
}
13 \lstinline{IdentityFile ~/.ssh/keyfile
}
17 \begin{frame
}[fragile
]
18 \frametitle{Public key authentication
}
19 \framesubtitle{Genereren van een sleutelpaar
}
20 \begin{block
}{\$ ssh-keygen
}
22 Generating public/private rsa key pair.
23 Enter file in which to save the key (/home/frobnicator/.ssh/id_rsa):
24 /home/frobnicator/.ssh/github
25 Enter passphrase (empty for no passphrase):
26 Enter same passphrase again:
27 Your identification has been saved in /home/frobnicator/.ssh/github.
28 Your public key has been saved in /home/frobnicator/.ssh/github.pub.
29 The key fingerprint is:
30 92:
92:
6e:b8:
3f:d5:
76:e8:
1b:
73:ed:
97:c4:e5:
87:ba frobnicator@foobarbaz
31 The key's randomart image is:
47 \begin{frame
}[fragile
]
48 \frametitle{Public key authentication
}
49 \framesubtitle{Installeren van een sleutel
}
50 \begin{block
}{Publieke sleutel:
\textasciitilde/.ssh/github.pub
}
52 ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDBrgcK05XzRRbtmPyXQner5ef8
53 suOAErDvInRDQbl2bjR0PGizL2t5lM9zE+mS0HHigteGLKma1NxVBBeam0CrodJN
54 BcW55x3LR/
2fLSujUqcloQNwLUpD5da6eGg9yPo1fEaAOK1ssHGA30o6nmDEZEHy
55 PFgBtPwtDw5TPXPpzslaJx1u7CdeyzqpYsUycxzboy3GBcCsvG4nzD4C9vd0yk5o
56 jlDeECul4mwyg7NuEjltaY89RzrSa8NtqtURyg/JFQW2IVGe+oBXeTL/eQRuo1Nj
57 GhYyPm1VMVM+NvaYQZXxGfLpoDoP2V+deD+gP5DuC8WW4LSGnkHKhDEin0Yl foo
62 \begin{block
}{Geheime sleutel:
\textasciitilde/.ssh/github
}
64 -----BEGIN RSA PRIVATE KEY-----
65 9RnNnrD2DkJBqoX/Aph2wVZg1y/I8t27C7yPR66xUNyHWG4J+k+q7REhA/K4fvjl
66 NNvNtbc4EeNI+NxaaftH1qo6yBIF5yDwuEYKixeconLCeGl9/exdlyMyXbuuTrU9
67 d5DgKnWxgJPHnDjmwqTeX3A5S34m/qJKK67IF9WqedeHxeMKzMZYcZpcsFxdvHk/
69 -----END RSA PRIVATE KEY-----
73 \begin{block
}{Installeren op de server
}
74 De inhoud van het publieke bestand moet in
75 \lstinline{~/.ssh/authorized_keys
} komen te staan
79 \begin{frame
}[fragile
]
80 \frametitle{Public key authentication
}
81 \begin{block
}{\textasciitilde/.ssh/authorized
\_keys}
83 option1="option1value",option2="option2value"...optionn="optionnvalue" ssh-rsa\
89 \begin{frame
}[fragile
]
90 \frametitle{X forwarding
}
92 Grafische programma's draaien op een machine die niet perse binnen
96 \begin{block
}{Command line vlag
}
97 \lstinline{ssh -X frobnicator@foobarbaz.com
}
100 \begin{block
}{Config file
}
101 \lstinline{ForwardX11 yes
}
104 \begin{block
}{Caveat
}
110 \frametitle{Port forwarding
}
112 Onversleutelde communicatie versleutelen
115 \begin{block
}{Command line vlag
}
116 \lstinline{ssh -L port:host:hostport frobnicator@foobarbaz.com
}\\
117 \lstinline{ssh -R port:host:hostport frobnicator@foobarbaz.com
}
120 \begin{block
}{Config file
}
121 \lstinline{LocalForward port host:hostport
}\\
122 \lstinline{RemoteForward port host:hostport
}
127 \frametitle{Agent forwarding
}
129 Je SSH cache meenemen naar een andere server
132 \begin{block
}{Command line vlag
}
133 \lstinline{ssh -A frobnicator@foobarbaz.com
}
136 \begin{block
}{Config file
}
137 \lstinline{ForwardAgent yes
}
142 \frametitle{SOCKS proxy
}
144 Al je internet verkeer via een
\textit{vertrouwde
} locatie laten lopen
147 \begin{block
}{Command line vlag
}
148 \lstinline{ssh -D port frobnicator@foobarbaz.com
}
151 \begin{block
}{Config file
}
152 \lstinline{DynamicForward port
}
155 \begin{block
}{Instellen in Chromium
}
156 \lstinline{chromium --proxy-server="socks5://host:
8080" --host-resolver-rules="MAP *
0.0.0.0 , EXCLUDE host"
}
161 \frametitle{Instellen in Firefox
}
162 Edit - Preferences - Advanced - Network - Settings
163 \includegraphics[width=
200px
]{./img/firefox_socks.png
}
166 \begin{frame
}[fragile
]
167 \frametitle{Compression
}
172 \begin{block
}{Command line vlag
}
173 \lstinline{ssh -C frobnicator@foobarbaz.com
}
176 \begin{block
}{Config file
}
177 \lstinline{Compression yes
}