[pkg-cryptsetup-devel] Bug#901795: cryptsetup-initramfs: please provide documented shell functions to validate/sanitize cryptroot entries in 3rd party hook files

Christoph Anton Mitterer calestyo at scientia.net
Sat Sep 11 21:01:52 BST 2021


On Sat, 2021-09-11 at 21:55 +0200, Guilhem Moulin wrote:
> The use of `printf %b` to decode escape sequences is an internal
> implementation detail; documenting it would tie our hands for
> implementation changes…
> 
> Also there is no guaranty that /bin/sh is dash; don't forget that we
> also run at initramfs stage where /bin/sh is typically `busybox ash`
> (but again no guaranty, it can be dash, bash, klibc's sh, or anything
> else) for which `printf %b` *does* decode \xHH.

True.
Well then best is probably to e.g. document the \0xxx and mention that
any other use of \ needs to have that quoted or it may have a special
meaning?

That should neither over- nor under-specify it.


Cheers,
Chris.
> > 



More information about the pkg-cryptsetup-devel mailing list