From: Daniel Hofstetter <dhofstet@gmail.com>
To: 69546@debbugs.gnu.org
Subject: bug#69546: cksum: inconsistent handling of invalid length values
Date: Mon, 4 Mar 2024 16:44:54 +0100 [thread overview]
Message-ID: <CAFRQvFq65eAQVsL_Yks3YdOzbuzW-QLcoggtKGS2=g3BP3afyA@mail.gmail.com> (raw)
Hi,
When specifying an invalid length value followed by a valid length
value I get the following error:
$ printf "hello" | cksum --algo=blake2b --length=12 --length=8
cksum: invalid length: ‘12’
cksum: length is not a multiple of 8
However, if the invalid length value is a multiple of 8 and greater
than 512 (the maximum digest length for blake2b), there is no error:
$ printf "hello" | cksum --algo=blake2b --length=123456 --length=8
BLAKE2b-8 (-) = 29
I think the behavior should be the same in the two scenarios, whether
it's showing an error or ignoring the invalid value.
I'm using coreutils 9.4.
Regards,
Daniel
next reply other threads:[~2024-03-04 15:45 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-04 15:44 Daniel Hofstetter [this message]
2024-03-04 16:39 ` bug#69546: cksum: inconsistent handling of invalid length values Pádraig Brady
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://lists.gnu.org/mailman/listinfo/bug-coreutils
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAFRQvFq65eAQVsL_Yks3YdOzbuzW-QLcoggtKGS2=g3BP3afyA@mail.gmail.com' \
--to=dhofstet@gmail.com \
--cc=69546@debbugs.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).