For reference:
Patches for Whonix live by Algernon-01 · Pull Request #1 · Kicksecure/developer-meta-files · GitHub
https://github.com/Whonix/anon-meta-packages/pull/6
https://github.com/Whonix/whonixcheck/pull/7
https://github.com/Whonix/apparmor-profile-gwenview/pull/1
https://github.com/Whonix/whonix-ws-network-conf/pull/1
https://github.com/Whonix/whonix-gw-network-conf/pull/1
Patches for Whonix live by Algernon-01 · Pull Request #20 · Kicksecure/sdwdate · GitHub
Patches for Whonix live by Algernon-01 · Pull Request #1 · Kicksecure/apparmor-profile-hexchat · GitHub
https://github.com/Whonix/apparmor-profile-virtualbox/pull/1
Patches for Whonix live by Algernon-01 · Pull Request #2 · Kicksecure/apparmor-profile-torbrowser · GitHub
https://github.com/Whonix/apparmor-profile-okular/pull/1
https://github.com/Whonix/Whonix/pull/414
All non-controversial stuff (apparmor) already merged.
Regarding Patches for Whonix live by Algernon-01 · Pull Request #1 · Kicksecure/swap-file-creator · GitHub could you please simplify
if [ -z "$(cat /proc/cmdline | grep "root=live:")" ]; then
do_start
else
echo "Live mode detected. Swap file creation skipped. "
exit 0
fi
to
if cat /proc/cmdline | grep "root=live:" ; then
echo "Live mode detected. Swap file creation skipped."
exit 0
fi
do_start
Does that work?
Patches for Whonix live by Algernon-01 · Pull Request #1 · Kicksecure/swap-file-creator · GitHub
Why do you set SHRED_ON_STOP="yes"
unconditionally for non-live Whonix?
Is that an unrelated suggestion / fix?
Patches for Whonix live by Algernon-01 · Pull Request #1 · Kicksecure/swap-file-creator · GitHub
Why do you add --remove
to SHRED_OPTS
?
Is that an unrelated suggestion / fix?
https://github.com/Whonix/Whonix/pull/414 is wrong. packages/dracut-live-patches must not be a pull request against Whonix/Whonix. dracut-live-patches has to go into its own git repository, ideally https://github.com/Algernon-01/dracut-live-patches. You could do that by creating a github repository dracut-live-patches
.
Whonix/packages/dracut-live-patches/debian/dracut-live-patches.postinst at 09e18cd48b0c5f069f028c6c59db466b13ecf5c5 · Algernon-01/Whonix · GitHub
Why is dracut /boot/initrd.img-$i $i
required? Shouldn’t the dracut package by Debian already do that?
Whonix/packages/dracut-live-patches/debian/dracut-live-patches.postinst at 09e18cd48b0c5f069f028c6c59db466b13ecf5c5 · Algernon-01/Whonix · GitHub
Same for update-grub
.
packages/dracut-live-patches/debian/dracut-live-patches.preinst
does nothing so can and should be safely removed.
https://github.com/Whonix/Whonix/pull/414/files#diff-03db39ec0efb2a7676d8fb370a47a075R14
Since you have no man pages, this can be removed:
+override_dh_install:
+ make manpages
+ dh_installman $(CURDIR)/debian/tmp-man/*
packages/dracut-live-patches/etc/apparmor.d/tunables/alias.anondist
I doubt a .anondist
file / config-package-dev is needed here. And should be avoided at all cost if possible.
I guess a file dracut-live-patches/etc/apparmor.d/tunables/dracut-live-patches
with the same contents would do?
packages/dracut-live-patches/etc/apparmor.d/tunables/home.d/whonix
A generic package dracut-live-patches
shouldn’t have a file named whonix
, since not a Whonix specific package.
packages/dracut-live-patches/man/dracut_live_patches.8.ronn
should be deleted - if there is no user facing tool started from the command line, we don’t need a man page, right?
These files contain a lot code:
- dracut-live-patches/etc/grub.d/11_linux_live
- dracut-live-patches/usr/lib/dracut/modules.d/90dmsquash-live/dmsquash-live-root.sh.anondist
- dracut-live-patches/usr/lib/dracut/modules.d/90dmsquash-live/module-setup.sh.anondist
I don’t understand that code very well. Would take me a long time to learn. Cannot simply merge on a “non-malicious just works” basis since that could lead to a lot pressure and headache later when it breaks.
initramfs currently is something that “Debian does”, “that just works”, “that is used by very many people and unlikely to break”. So that requires very little thought, maintenance and time from me.
The suggested code by you is complex so I try to figure out if my time to learn it is well justified and the-clean-way™ to do things.
Correct me if I am wrong, but I understand, the majority of the file has been written by third parties. (Indicated by the copyright of the file.)
What’s the original source of dracut-live-patches/etc/grub.d/11_linux_live so I can see the diff? I couldn’t find it.
Looking at the diff for the two dracut modified files… Using the dracut version from stretch…
diff /usr/lib/dracut/modules.d/90dmsquash-live/dmsquash-live-root.sh yours
31c31
< [ -z "$overlay_size" ] && overlay_size=512
---
> [ -z "$overlay_size" ] && overlay_size=32768
266a267,271
> else
> BASE_LOOPDEV=$( losetup -f )
> umount /run/initramfs/live
> losetup -r $BASE_LOOPDEV $livedev
> do_live_from_base_loop
290a296
>
[ -z "$overlay_size" ]
indicates, that this can be configured somewhere. Please:
- try to find out the configuration file (so we can just ship a config snippet rather than config-package-dev divert the whole script
- ask upstream if you are unable to find it
- if there is no config file, please submit a patch to upstream to make that configureable
- only as very last resort, if upstream refuses to cooperate we consider to fork this file and carry a patch
The part after the else
looks strange. The intend style confused me. Please fix intend style. I guess you meant like this?
if [ -n "$FSIMG" ] ; then
...
else
BASE_LOOPDEV=$( losetup -f )
umount /run/initramfs/live
losetup -r $BASE_LOOPDEV $livedev
do_live_from_base_loop
fi
Same as above. Please work with upstream dracut to get this merged.
diff /usr/lib/dracut/modules.d/90dmsquash-live/module-setup.sh new
20c20
< instmods squashfs loop iso9660
---
> instmods squashfs loop iso9660 overlay
25c25
< inst_multiple umount dmsetup blkid dd losetup grep blockdev find
---
> inst_multiple umount dmsetup blkid dd losetup grep blockdev find df tail
39a40
>
I don’t understand the diff.
Same. Could you work with upstream please to make this the default or easily configurable? (The ideal configurability would be a .d
drop-in folder for config files.)