简体   繁体   中英

Add text to .jpg/png/gif

I heard there is some way, to add additional hidden text inside code of the image file (like jpg/png/gif).

If we open this image in windows, will be shown a picture, but if we open it by some text-editor (like notepad++), we will see our hidden text.

How is this method called? What can you say about it?

Thanks.

This is called steganography .

I think its primary industrial use is watermarking content.

Information Hiding: Steganography & Digital Watermarking is a good resource on the topic.

Look up steganography. There are lots of tools to add any kind of hidden data you want in there. Usually though, it's not readable by notepad though. you need a companion tool to the one you used to add the data in in the first place. Using this you can even hide a binary file inside.

OR... you could look into using the metadata -- EXIF -- of the JPEG. Lots of tools exist to edit that data too. It ends up stored in the header of the file, so it should be right near the beginning, in other words the file would look something like:

JFIF ..... (GARBAGE) ..... Your Metadata ...... (GARBAGE)

Or finally, I hear that you can just concatenate a RAR onto the end of a JPEG and it will work as a (strangely huge) JPEG but WinRAR will notice the RAR contents when you open it in WinRAR.

Use " copy " - copy two files in one.

copy /B img.jpg + some.txt

Thus both file will be merged into the img.jpg file. The text from some.txt is append to the end of the img.jpg file.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM