How steganography is implemented in php

Somewhere I discovered steganography .. a way to store or hide information in other information .. sometimes certain images are also used to hide information. Can I get an example or something else to learn more about how this is implemented ... or if at all it is possible to use this in php

+6
php steganography
source share
4 answers

You want the GD library in PHP to process JPG images: http://php.net/manual/en/book.image.php

To understand steganography and steganalysis, read this article: http://www.securityfocus.com/infocus/1684

+4
source share

As a rule, if you are talking about steganography, then basically you fill in the information in the nooks and cranks of the image file. You can use almost any image library there until the image library validates the image file strictly against the circuit. You can use almost any programming language that you like.

There are many methods. Here are some that are easy to program.

  • Use the image format in which the image is stored in pieces. You can move chunks to allow spaces in the file. You can then hide lines of information in spaces.
  • Convert an image to an indexed image. Declare a palette more than the number of colors. Now you can hide additional information in the palette of colors not used in the image.
  • If you use an image format that has layers, you can declare a layer in which the alpha channel is at its maximum. This makes the layer completely transparent. You can use a different color channel to hide your data.

There are many other methods. Remember to use generous amounts of compression and random misleading data to make the image file look legit.

+6
source share

Here is a class from phpclasses.org for

Hide encrypted data on images using steganography

Some useful links from the Steganography page on Wikipedia

Finally, another demo and source code here

+4
source share

One common way to do steganography:

Think of a 1024 x 768 24-bit color (i.e. 8 bits of red, 8 bits of yellow, 8 bits of blue) of an image. Now the least significant bit of colors in the image does not matter much. Therefore, you can hide three bits of information in each pixel.

This makes for 1024 * 768 * 3/8 or 294,912 bytes of information that can be hidden in a large image without significant image degradation.

+3
source share

All Articles