Open michael-o opened 3 years ago
@michael-o so if I am understanding this, it is the sed statement that is messing up the spaces? Only that line??? Your last statement makes me ask is this an issue with how that sed line is escaped for spaces and NOT an actual Bastillefile error. Am I reading this wrong???
@michael-o so if I am understanding this, it is the sed statement that is messing up the spaces? Only that line??? Your last statement makes me ask is this an issue with how that sed line is escaped for spaces and NOT an actual Bastillefile error. Am I reading this wrong???
IIRC, the sed
statement isn't a problem, but the preprocessing shreds it, not putting in-line spaces into account. The combination of SCRIPT
and the subshell.
[MANDATORY] Describe the bug [MANDATORY] If your Bastillefile contains more than one space in one line this block: https://github.com/BastilleBSD/bastille/blob/b85d6347dee44c943819c2d7b4eee9c5a30535b5/usr/local/share/bastille/template.sh#L267-L268 kills it.
[MANDATORY] Bastille and FreeBSD version (paste
bastille -v && freebsd-version -kru
output) 0.8.20210115 12.2-STABLE 12.2-STABLE 12.2-STABLE[MANDATORY] How did you install bastille? (port/pkg/git) ports
[optional] Steps to reproduce? Add this to your
Bastillefile
:Run the following:
Looks good. Now do this:
My spaces are now gone and
ssh_config
cannot be modified bysed
.[optional] Expected behavior No mangling is multiple consecutive spaces
[optional] Additional context I guess a while loop would be much better here. A workaround is to write instead of a space a
\
.