I read Pseudo code to find Bip39 checksum? and followed the steps outlined by the answer and arrived at the correct checksum.
But when I went to try it on a 128 bit entropy that were all 1s: 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111
I got the wrong checksum (checking with https://iancoleman.io/bip39/ and https://learnmeabitcoin.com/technical/mnemonic).
On ubuntu 20.04, I ran:
echo "11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111" | shasum -a 256 -b
and my hash was
951354377d60faddeaf27bbc864565a2fef8db8da4b4bdf5c21a2c6f6ac9a06f
so, reading from the Bip39 spec (https://github.com/bitcoin/bips/blob/master/bip-0039.mediawiki#Generating_the_mnemonic), it says "A checksum is generated by taking the first ENT / 32 bits of its SHA256 hash. This checksum is appended to the end of the initial entropy."
So I took the first four bits of the hash, 9 in hex is 1001, and appended it to the 128 1s so now the checksum word should be 11111111001, and checking it on https://github.com/hatgit/BIP39-wordlist-printable-en/blob/master/BIP39-en-printable.txt tells me that my checksum word should be "you".
Therefore, shouldn't my 12 word mnemonic now be:
zoo zoo zoo zoo zoo zoo zoo zoo zoo zoo zoo you
?
But importing the 128 1s as entropy into https://iancoleman.io/bip39/ (checking the box for "Show entropy details"), tells me my last word should be "wrong", so "you" is incorrect.
Can someone please point out what I'm doing wrong? This is driving me a little crazy. Thanks!