We have a key representing an SHA-256 hash in HEX, and we have the key in AES-ECB. We also have a file with plaintext to cipher messages that were encrypted with our key. How could we find this key?
8cb78d34edfec9db1fa4a044f14c06cd5d9aa8a4fece263c439c5fa62dd1fedadf757d79fa6a28069ddcba4ca624c9694559483254896625392f70bf7df4dd66
The above is the flag encrypted in AES-ECB, we know that the flag is a hex representation of an SHA-256 hash:
79621ca63d052e64 --> ca5b6fdb77e3b1ec39b6c4e1a4b69ba5
55191c3c4eeb107e --> ded63de07b250d83f842d7bc860db40c
We have a whole list with plaintext that was encrypted with our key (flag).