Double Hash

May 1 2017

# # # #

one fish twofish red fish blowfish

0xcaae8ee4f458ff776860e57141313e1e145423932e79e799d5133af8610e40d 94299046d28022d0b0efaa7fd3177b87e8e8530667111180e47da98f84846d753 cf9afa7c2635c93cf93ef8035b2217c05e192e3d2547e084c86085c2b83ef2b5


The hint says one fish twofish red fish blowfish. This is a vague hint. But it gives me two ciphers. twofish and blowfish. This is evident because the word "twofish" is a single word. The two hash functions can now be combined in a few different ways. If we call them h1 and h2, we can have the following.

  • h1(x) + h2(y) => Addition
    • This does not work. Because the addition of two hash functions will make it impossible to recover the original hash.
  • h1(x) | h2(y) => Concatination
    • This is plausible. But look at the sizes of the hashes. For the concatination operation, the hash would be much much larger in size for a reasonably sized cipher text.
  • h1(h2(x)) => Chaining
    • This is plausible too. And it also benefits from a single cipher text instead of the multiple texts for the other ones.

The 0x prefix explains that this is a hexadecimal.

Both these have a word prefixed to them. one fish twofish red fish blowfish. I try out what I get when I use these strings as the "key" for the ciphers. Since we don't have any additional information about any kind of initialization vectors, we can ignore them, and run the cipher under ECB mode. A hint was also added to make this obvious that ECB is to be done.

After trying a few combinations, we do end up with a valid output.

Decryption of the cipher text with ECB, key red fish, and cipher blowfish gives us d378383f7995e22f97ba3e88bd1eb97b68620c6d965c531e238ae40cfc8e73b75f7ae130215d0bb62d42f61dc3d71939.

Decryption of this with key "one fish", and cipher "twofish" gives us the flag "one fish twofish red fish blowfish".


one fish twofish red fish blowfish

Recommended Reading

Royal Primes

# # #

c = 2911901299590689319468053634625275622654003904978205739380623481723661641396883678700531176998074009090944130064383792213854734101182591054606781359574544120823690362905523398270489939706547990345246231530733316646360394579721797156381054207414615333776383945252214100458075195770993971636731892198913293107313263096802400950280001995889600269261084002962194522369348371580184194201319826916320073496756736378234176527727677896098180012125139057850531341929674855173384488699967535868594673470466436155672157436157446615623094626238560694456848398206751930925254978950059694877328019092454478343535457958785859310484


Recommended Reading


# # # # #

Find the flag.

  • Flag Format /flag:[a-zA-Z]+/

Provided Macbeth.docx

Hint : Not all characters are created equal.


Opening the file we can quickly tell that the entire file has been written in two fonts. We unzip the docx file, and grep...