From mboxrd@z Thu Jan 1 00:00:00 1970 Path: eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: wvxvw Newsgroups: comp.lang.ada Subject: Re: GNAT.SHA256 produces result different from sha257sum on Linux Date: Sat, 04 Nov 2023 17:48:03 +0100 Organization: A noiseless patient Spider Message-ID: <877cmxh3cs.fsf@gmail.com> References: <87bkc9h9au.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain Injection-Info: dont-email.me; posting-host="d272cbac82ad59a2f68bf01ec9dc5e6d"; logging-data="3627524"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19EBmQJ2emxX2+NcvjYQrzQ" User-Agent: Gnus/5.13 (Gnus v5.13) Cancel-Lock: sha1:dl7hTi3+2lHmEhsdDbe7PRyrSLg= sha1:BxpWLBocz5oAxLbg8r3kl5FgEGs= Xref: news.eternal-september.org comp.lang.ada:65838 List-Id: "Jeffrey R.Carter" writes: > I think the problem may be that echo adds an LF: > > $ echo foo | hd > 00000000 66 6f 6f 0a |foo.| > > Since sha256sum expects to work on arbitrary files, it would include > the LF in its input. Hi, thanks for the idea, but no, that's not it. With the line end added I get 04e1806fda6bdbc9e5e3534edd993c7c2bf03173f5489742db53d1e8b0ef8c61 from Ada.