Somewhere I found out steganography .. the way of storing or hiding information within another information.. at times certain images are also used to hide the information.. Can i get an example or any thing further to know more about how this is implemented... or if at all is it possible to use this in php
You want the GD library in PHP to manipulate JPG images: http://php.net/manual/en/book.image.php
For an understanding of Steganography and Steganalysis, read this article: http://www.securityfocus.com/infocus/1684
Generally , if your talking about steganography, then basically you are stuffing information into the nooks and crannies of the image file. You can use nearly any image library out there as long as the image library doesn't validate the image file strictly against a schema. You can use nearly any programming language you fancy.
There are numerous techniques. Here are some which are easy to program.
- Use an image format which stores the image in chunks. You can move the chunks to allow gaps in the file. You can then hide strings of information in the gaps.
- Convert the image to an indexed image. Declare a pallete larger than the number of colors. Now you can hide extra information in the pallete colors not used in the image.
- If you are using an image format which has layers, you can declare a layer in which the alpha channel is maximum. This causes the layer to be fully transparent. You can use another color channel to hide your data.
There are numerous more techniques. Remember to use generous amounts of compression and random misleading data to make the image file look legitimate.
You want the GD library in PHP to manipulate JPG images: http://php.net/manual/en/book.image.php
For an understanding of Steganography and Steganalysis, read this article: http://www.securityfocus.com/infocus/1684
One common way to do steganography:
Think about a 1024 x 768, 24-bit color (i.e. 8 bits of red, 8 bits of yellow, 8 bits of blue) image. Now, the least-significant bit of the colors in the image doesn't matter much. Therefore, one can hide three bits of information in each pixel.
That makes for 1024 * 768 * 3 / 8, or 294,912 bytes of information that can be hidden in a large image without degrading the image much.
Here is a class from phpclasses.org for
Hide encrypted data in images using steganography
Some useful links from Steganography page at wikipedia
At last one more demo & source code over here
© 2022 - 2024 — McMap. All rights reserved.