Before I could start creating a program, I had to research about the composition of digital images. For example I learned that the colour of digital images is made up of 3 different parts, the red, green, and blue, the primary colours. Using combinations from these, any colour can be made. Each component has a maximum value of 255 (decimal), or 8 bits (11111111 in binary). Three of these 8 bit components total 24 bits , which is how we get 24 bit pictures. These values can also be represented in red, green , blue hexadecimal format.
Steganographic images are made up of two basic layers. When combined, the cover image and the embedded message make a steganographic image. A stego-key(type of password or encoding method) must be used while encoding. If a person knows the key, they can decode the picture. The encoding key states what pixels to get and how to read the information once the pixel colour is retrieved.
If you are looking for a picture to encode, you must be careful of the ones you choose. An image with large areas of solid colours is a poor choice, as variances created from the encoded message will be noticeable in the solid areas. It helps to encode the message in an area of the picture that is more "noisy" and has more colours. This will draw less attention. A good technique is to spread the message randomly throughout the image. Some common approaches used to conceal messages are, least significant bit insertion, masking and filtering, and transformations. All of these techniques can be applied, and each of them will have success on various pictures. In my program I modified a method called the least significant bit insertion technique.
The way that LSB (Least Significant Bit) works is actually quite straightforward. As I have mentioned , each pixel has a Red, Green, and Blue value. In binary, that is made up of 1s and 0s. Each R,G,B component is represented by 8 bits (eg.00010110). Using the LSB method of encoding, only 1 or 2 bits of that binary value are changed. For example, to encode letter A, you would give it a predefined number code, covert that to binary, and take the binary bits of that number and replace them in the r, g, or b component. The great advantage with this method is that binary numbers only have two possible values 1 and 0.There is a 50% chance that you will not change a bit at all.
My LSB techniques this year changed only two bits from each r,g,b (raw data bytes) component of a pixel. Now since it takes 8 bits to represent a letter this technique would need at least 4 bytes for each letter in a message. This means I needed one extra byte. I choose one extra blue byte because most people are least sensitive to blue and most sensitive to green. I used this same basic technique to stego avi and wav files also. I used 4 raw wav data file bytes (representing sound bytes) and 4 raw avi data file bytes (representing audio/video) to hide the patient info.
There are several ways to encrypt your letters before placing each character as a coloured pixel in an image. When you type in a letter on your keyboard, a special code called ASCII code is sent back to your computer. Every key on your keyboard has its own unique ASCII code, so the key can be identified. Once this number is transmitted to the computer, it can be converted to binary, and using the LSB method, inserted into a picture. This year I used this basic idea combined with some cryptographic techniques, which I detail later in the research.
While researching I learned that the encoding works best with BMP formated pictures. Many BMP pictures are in high quality, 24-bit format. Sometimes this is referred to as true colour format. We need 24-bit images if we want to add data to the least significant bits . In true colour graphics, like BMP, each dot or pixel is represented by 3 bytes (or 24 bits). Each byte is 8 bits long, and this totals 24 bits. One byte represents the value of an additive mix-colour(Red, Green, Blue). Because one byte can represent 2 to the power of 8 (256) different values (0-255),one pixel alone can have(256 x 256 x 256, or 2 to the power of 24) 16 777 216 different colour values!!! . Try encoding an image, and compare it to the original. You won't notice any difference. The human retina becomes the limiting factor when viewing 24-bit(True Colour) pictures. The smallest difference between two pixels in the 24-bit palette isn't even noticeable to the human eye! This is why 24-bit graphics are really called "True Colour" graphics.This year I had to also work with 8 bit colors images, which don't hide the data as well. The only saving grace was that most medical images are in grey scale where the changes in the palette (color table) are very gradual. This helps with the embedding process. More details follow later in the research.