0
$\begingroup$

This question is related to "Is it safe to initialize a random number generator with MD5?".

But in the context of steganography we don't know which pixels have been selected to hide information. In addition, the content could be encrypted, so we do not know if the hidden information that we extract (with a guessed password) is the message or noise.

In this scenario, is it safe to initialize a PRNG with the MD5 hash of a password? and what interests me the most: if it is not, how can it be exploited?

$\endgroup$
3
  • 2
    $\begingroup$ Without specification of the steganography system, it's impossible to tell how much time it would take to test if a password is valid. I thus see no way to rationally answer the question, other than by: the system would be safer with proper key stretching in the password-to-PRNG-seed derivation. $\endgroup$
    – fgrieu
    Oct 21, 2022 at 6:09
  • $\begingroup$ @fgrieu I have edited the question. what I would like to know is how to carry out an attack if I don't know if the result of the password that I try in each case is correct, since I don't know if what I have extracted is an encrypted message or noise. Or put another way, I don't know if the correct pixels of the image are being selected. $\endgroup$ Oct 21, 2022 at 7:32
  • 2
    $\begingroup$ Without specification of the steganography system, I don't see what to add to the second part of my earlier answer, which does cover how to attack a generic (CS)PRNG-seeded-by-fast-hash-of-password system. $\endgroup$
    – fgrieu
    Oct 21, 2022 at 9:24

1 Answer 1

1
$\begingroup$

Is it safe to use MD5 as a redundant step in an otherwise secure setup? yes.

Is using MD5 to garble a low entropy password safe? No, because one would iterate through the passwords and check if the selected pixel seem to be modified, and identify the correct password.

In fact if you use the same password for pixel selection and encryption, It may be possible to break an otherwise strong encryption.

One can use image processing techbiques to asses how likely a specific pixel is to have been modified, and compare different possible collectiona of pixels. Not sufficient if we have too many possible options but with a reasonable dictionary probably solveable.

If you have a strong independent encryption and the modification to the image is not detectable at all, and the original password ia very high entropy, you don't need MD5 at all in the first step.

What is the purpose of MD5 in your scheme? It doesn't seem to add anything.

$\endgroup$
1
  • $\begingroup$ This is not my scheme, it is an old software that I am analyzing. Thanks for your answer. $\endgroup$ Oct 21, 2022 at 12:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.