You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Since #6256, we accept -c, and callers think that we actually verify the checksum of some files. However, we always exit with 0, yielding obvious false-positives like this:
$ cargo run -q cksum -a md5 /dev/null # SetupMD5 (/dev/null) = d41d8cd98f00b204e9800998ecf8427e
$ cat <<EOF >foo.sums # More setup
> MD5 (/dev/null) = d400000000000000000000000000007e
> EOF
$ cksum -a md5 -c foo.sums # Should reject/dev/null: FAILEDcksum: WARNING: 1 computed checksum did NOT match[$? = 1]
$ cargo run -q cksum -a md5 -c foo.sums # But we accept?!MD5 (foo.sums) = 396bec11fe90bdaf047158984c99546c
$
This is a bad situation. Let's either actually support -c or not support it, but "accepting the argument and ignoring it" is a security disaster waiting to happen. This is already planned to be fixed, and perhaps even partially finished. This issue exists because I'm paranoid that we might still somehow forget to do it :D
The text was updated successfully, but these errors were encountered:
Since #6256, we accept
-c
, and callers think that we actually verify the checksum of some files. However, we always exit with 0, yielding obvious false-positives like this:This is a bad situation. Let's either actually support
-c
or not support it, but "accepting the argument and ignoring it" is a security disaster waiting to happen. This is already planned to be fixed, and perhaps even partially finished. This issue exists because I'm paranoid that we might still somehow forget to do it :DThe text was updated successfully, but these errors were encountered: