01-edu / public

📚 @01-edu's Public Repository
http://public.01-edu.org/
224 stars 447 forks source link

[FEATURE] deep-in-system audit details #2543

Open jo-eman opened 5 months ago

jo-eman commented 5 months ago

In deep-in-system project instructs us to create disk partitions.

When these are created during ubuntu server LTS installation in UTM on Mac they end up as vda partitions.

However in the audit it is checked with specific command:

user:~$ lsblk -o NAME,FSTYPE,SIZE,MOUNTPOINT /dev/sda
NAME   FSTYPE SIZE MOUNTPOINT
sda            30G
├─sda<...>          1M
├─sda<...> swap     4G [SWAP]
├─sda<...> ext4    15G /
├─sda<...> ext4     5G /home
└─sda<...> ext4     6G /backup
user:~$

If you have vda partitions instead it does not exactly match the desired output even tho functionality is very similar and it satisfies these conditions: The VM disk size must be 30GB.

VM disk must be divided into these partitions: "swap:" 4G "/": 15G "/home": 5G "/backup": 6G

And it can be checked like this, but output is not exactly as in audit. joman@localhost:/etc/netplan$ lsblk -o NAME,FSTYPE,SIZE,MOUNTPOINT /dev/vda NAME FSTYPE SIZE MOUNTPOINT vda 30G \u251c\u2500vda1 vfat 1G /boot/efi \u251c\u2500vda2 swap 3.9G [SWAP] \u251c\u2500vda3 ext4 14.7G / \u251c\u2500vda4 ext4 4.7G /home \u2514\u2500vda5 ext4 5.6G /home/nami/ftp

It would be helpful to rephrase this adit requirement ot make it more generic to work from all platforms and different virtual machine software like UTM for Mac, and not match the exact output currently specified.

I think these conditions could be enough for the audit:

The VM disk size must be 30GB.

VM disk must be divided into these partitions: "swap:" 4G "/": 15G "/home": 5G "/backup": 6G

And ask to check it with lsblk command without requirement to match exact output.

Also the user is asked to create sha1sum of OVM. OVM is virtualbox specific. And trying to shasum the UTM file gives

shasum "ubuntu server.utm" shasum: ubuntu server.utm: Is a directory

because the utm file is a "package" similar to a directory. Maybe a possible workaround is to make a tarball of the utm and shasum it?

Oumaimafisaoui commented 2 months ago

Thank you @jo-eman for your feedback. It was communicated to the team, we will get back to you soon ! 🚀