# What is the security risk if an encryption key is not random?

Ok, I just jumped into crypto and now struggling with some points…

I read lots of resources, most of them mention how important the strength of the encryption key is. However, I could not find much info about that.

What if the encryption key is not generated randomly and somehow is fixed or easy to be guessed? And what if the key contains lots of zeros in it? What could be the security risks?

-

Back to your question: If the key is chosen poorly (and if there is some structure, the attacker knows it), it might be possible just to brute force it and try all possible keys. Today's computers can deal with complexities of testing $\approx 2^{64}$, therefore DES is no longer safe to use. If you know the first 100 bit of a 128 bit key are all 0 bits, then you probably are even able to find the key on any modern computer larger than a mobile phone.