bsdinstall: fix root password prompt with backslashes

Use "read -r" to set the root password in "bsdinstall rootpass" to
prevent issues with passwords containing one or more backslash
characters.

PR:		294781
Discussed with: tuexen, crest
Approved by:	khorben
MFC after:	3 days
Event:		Wiesbaden Hackathon 202604
This commit is contained in:
Lars Engels
2026-04-25 16:41:24 +02:00
parent 8f95b8b190
commit 1566386b90
+2 -2
View File
@@ -103,8 +103,8 @@ $errormsg" \
exec 5>&-
[ $res -eq $BSDDIALOG_OK ] || exit 0
echo -n "$output" | (read password1
read password2
echo -n "$output" | (read -r password1
read -r password2
[ -n "$password1" -o -n "$password2" ] || exit 62
[ "$password1" = "$password2" ] || exit 63
echo "$password1" | chroot $BSDINSTALL_CHROOT \