Test de l'état de sécurisation à la sortie de l'installation

  • Debsecan (apt update && apt install debsecan): listes des CVE qui peuvent être fixées

debsecan --suite $(lsb_release --codename --short) --only-fixed --format detail(--format packages permet même de récupérer la liste des paquets à mettre à jour via apt)

debsecan format detail

Image Not Showing Possible Reasons
  • The image was uploaded to a note which you don't have access to
  • The note which the image was originally uploaded to has been deleted
Learn More →

Installation de Lynis

apt update && apt install lynis 

Regarder les tutos de prise en main ci-dessous : copier le compte rendu fourni dans votre rapport

Pour exporter directement en html ou autre:

https://github.com/d4t4king/lynis-report-converter

le rapport lydis est contenu dans :

Image Not Showing Possible Reasons
  • The image was uploaded to a note which you don't have access to
  • The note which the image was originally uploaded to has been deleted
Learn More →

Effectuer un scan Lynis :

su - 
sudo lynis audit system

Install lyins exporter html

Dependances
​​​​# (as root)
​​​​apt update							# versions prior to Ubuntu 16.04 LTS should use 'apt-get'
​​​​apt -y install htmldoc libxml-writer-perl libarchive-zip-perl libjson-perl
​​​​apt install make
​​​​apt install git

​​​​pushd /tmp/
​​​​wget http://search.cpan.org/CPAN/authors/id/M/MF/MFRANKL/HTML-HTMLDoc-0.10.tar.gz
​​​​tar xvf HTML-HTMLDoc-0.10.tar.gz
​​​​pushd HTML-HTMLDoc-0.10
​​​​perl Makefile.PL
​​​​make && make install
​​​​popd
​​​​wget http://search.cpan.org/CPAN/authors/id/J/JM/JMCNAMARA/Excel-Writer-XLSX-0.95.tar.gz
​​​​tar xvf Excel-Writer-XLSX-0.95.tar.gz
​​​​pushd Excel-Writer-XLSX-0.95
​​​​perl Makefile.PL
​​​​make && make install
​​​​popd
​​​​popd


​​​​git clone https://github.com/d4t4king/lynis-report-converter.git
​​​​
​​​​cd lynis-report-converter
​​​​./lynis-report-converter.pl -i lynis-report.dat -o report_lynis_html
​​​​
​​​​
​​​​
​​​​##download the report on your local machine with scp##

Copie du report.html en local sur notre machine :

​​​​To exec in local terminal 
​​​​
​​​​scp -P 22 <USER>@<VM_IP>:/home/thompson/report.html /Users/thomas/Desktop/
Select a repo