Steganography
1 view (last 30 days)
Show older comments
Hey guys,
I met some problems in encrypting information hidden in an image. So I have two images: one with a white font and black text, and the other could be any image (the 2 images have the same size). First, I have to replace the least significant bit of the "red" color of the image with the information contained in the "textimage". Then, extract the part in the "red" color of the resulting image which correspond to the encrypted information.
Second, I have to use an encryption key that consists of a sequence of 1, 2 and 3, corresponding to the color planes on which information will be coded, i.e. if the key is 231321, the first pixel of the image "imagedetexte.bmp" will be encoded in level 2 (ie "green"), the second pixel is encoded in the plane 3 (ie "blue"), the third in a plan, the fourth in the plane 3, the fifth in the plane 2, the sixth in plan 1.
Also, the program will incorporate a Graphic User Interface.
To sum up:
1- The program asks if the user wants to encrypt or decrypt.
2- Depending on the user's response, it asks the names of image files to encrypt or decrypt.
3- Ask for the encryption key in the form of a series of 1s, 2s and 3s (in the case of encryption) or in the form of coefficients of a polynomial (in the case of decryption).
4- display the result (resulting image or coded key).
Thanks a lot.
Answers (3)
Image Analyst
on 26 May 2012
What does "one with a white font and black text" mean? Text appears in a font, so are your letters and words black, or are they white? You can' t have it both ways unless you have some letters black and some letters white or have large letters and have a pattern, like a spotted pattern on very big letters.
For #1, you might use questdlg(). For #2 you might use uigetfile() or dir(). For #3, you might use inputdlg(). For #4 you might use imshow(), or image().
0 Comments
Light
on 27 May 2012
11 Comments
Walter Roberson
on 31 May 2012
Convert the key from a decimal to a vector such as [2 3 1 3 2 1]. Then to know which plane to use for the K'th bit, access TheyKey(1 + mod(K-1, length(TheKey))) . Use if/else or switch() on that value to trigger the appropriate code.
Light
on 30 May 2012
1 Comment
Image Analyst
on 31 May 2012
You won't be getting help from me. Like I said, I don't know your program and don't really know encryption that well either. It's never really been a need for me or my images and programs.
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!