[prev in list] [next in list] [prev in thread] [next in thread] 

List:       busybox-cvs
Subject:    [Bug 14226] Busybox md5sum fails to support backslashes in filenames
From:       bugzilla () busybox ! net
Date:       2023-01-11 17:02:45
Message-ID: bug-14226-161-Nu885obOso () https ! bugs ! busybox ! net/
[Download RAW message or body]

https://bugs.busybox.net/show_bug.cgi?id=14226

--- Comment #1 from tlaurion <thierry.laurion@gmail.com> ---
The same behavior applies to sha256sum -c

For example (taken out of
https://github.com/osresearch/heads/pull/1262#issuecomment-1377744973)

cd /boot
mkdir "$(echo -e 'hidden dir\b\b\b\b\b\b\b\b\b\bshowed dir')"
cd *hidden*
touch "$(echo -e 'file with newline\ncharacter')"
touch "file with textual new\nline"
find ./ -type f ! -path './kexec*' -print0 | xargs -0 sha256sum > /tmp/test
sha256sum -c /tmp/test | grep -v 'OK' 
sha256sum: can't open './showed dir/file with newline': No such file or
directory
./showed dir/file with newline: FAILED
sha256sum: WARNING: 2 of 340 computed checksums did NOT match

cat /tmp/test
(exerpt)
e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855  ./showed
dir/file with textual new\nline
e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855  ./showed
dir/file with newline
character

cat /tmp/test | grep show
e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855  ./showed
dir/file with textual new\nline
e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855  ./showed
dir/file with newline

ls 
(exerpt)
hidden dir??????????showed dir

/boot # cd *hidden*
/boot/showed dir # ls
file with newline?character   file with textual new\nline

----
This impacts more than mda5/sha256: this extends to ls and other busybox
applets

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
busybox-cvs mailing list
busybox-cvs@busybox.net
http://lists.busybox.net/mailman/listinfo/busybox-cvs
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic