diff --git a/rendu.pdf b/rendu.pdf index 4288ce779894b5b4236a9e02a845332b194040e3..4872a15e269021541ccda30595bd3123cba18c43 100644 Binary files a/rendu.pdf and b/rendu.pdf differ diff --git a/rendu.tex b/rendu.tex index 7a914851ec21455eb878e19afb8403f61ad53d8b..ad609464ffb21364306be2f3a31d936ed8042be9 100644 --- a/rendu.tex +++ b/rendu.tex @@ -113,7 +113,7 @@ Ajouter \verb|$(vagrant_prompt_info)| au PROMPT dans le themes \subsection*{\#10} \section{SSH} -\subsection*{#1} +\subsection*{\#1} \begin{lstlisting} ssh alice@192.168.56.2 @@ -121,6 +121,53 @@ ssh alice@192.168.56.2 L'history des utilisateurs sont vides. +\subsection*{\#2} + +\begin{lstlisting}[language=bash] +bob@srv:~$ ssh-copy-id alice@192.168.56.3 +/usr/bin/ssh-copy-id: INFO: Source of key(s) to be installed: "/home/bob/.ssh/id_rsa.pub" +alice@192.168.56.3's password: + +Number of key(s) added: 1 +\end{lstlisting} + +Après la copie de la clef bob peut se conecter sans le mot de passe de alice. + +\begin{lstlisting}[language=bash] +ssh-agent +ssh-add +Ces commandes permettent de ne pas taper le mot de passe a chaque connections. +\end{lstlisting} +\subsection*{\#3} + +\begin{lstlisting}[language=bash] +alice@cli:~$ ssh-keyscan 192.168.56.3 > .ssh/known_hosts +# 192.168.56.3:22 SSH-2.0-OpenSSH_7.4p1 Debian-10+deb9u7 +# 192.168.56.3:22 SSH-2.0-OpenSSH_7.4p1 Debian-10+deb9u7 +# 192.168.56.3:22 SSH-2.0-OpenSSH_7.4p1 Debian-10+deb9u7 +alice@cli:~$ ssh bob@192.168.56.3 +bob@192.168.56.3's password: +\end{lstlisting} +\subsection*{\#4} + +\begin{lstlisting}[language=bash] +ArchNilux% sftp alice@192.168.56.2 +alice@192.168.56.2's password: +Connected to 192.168.56.2. +sftp> put Vagrantfile +Uploading Vagrantfile to /home/alice/Vagrantfile +Vagrantfile 100% 1419 875.2KB/s 00:00 +sftp> get /etc/passwd +Fetching /etc/passwd to passwd +passwd 100% 1640 534.1KB/s 00:00 +sftp> ^D + +sshfs alice@192.168.56.2:/home tmp +\end{lstlisting} +Le fichier a bien été modifié sur le home d'alice +\subsection*{\#5} + + \section{Git} \subsection*{\#1} \begin{lstlisting}[language=bash]