Michal Stanek @ 36c3 Profile picture
Programming | Low-level | Comp Arch | Security | Tea
Assaf Nativ Profile picture 1 subscribed
Jan 22, 2019 9 tweets 6 min read
So I wanted to encrypt some files. Thought about using 7z+password. Stackexchange folks said "Didn't review it but it should be fine. You can browse the code yourself". So I did. After a few mins I noticed they use 8byte "random" IV. Yes, half of IV is zeroes. But it gets worse. Aside from the fact that 7z XORs plaintext with zeroes, I was curious about the "RandomGenerator" which generates IV. That's when I vomited. The first comments say "This is not very good random number generator. Please use it only for salt." It is not used only for salt.