Re: Embedding Graphics.
- Posted by Robert B Pilkington <bpilkington at JUNO.COM> Mar 30, 1998
- 1026 views
>I want tamper-proof graphics for my programs (i.e.: Someone could >change a bmp or gif file that is just hanging around in the executables >directory to whatever they want....) What is the best way to embed or >keep graphics from being changed by users? I would like to use gifs in >my programs due to the size of the files. I am currently using Michael >Bolin's GIF loader to load graphics into my program. Let me know what the >best way to mask or embed my graphics might be. Please include any source >that might be helpful if it is handy! You could run a simple encryption of the files, enough to scramble the data so editing programs don't recognize them and then decrypt the data as it's being loaded. (Something as simple as adding a certain number to the byte value and then wrapping it if it goes above 255, then subtracting that number to decrypt.) You would need to edit the GIF loader routines to subtract the number before doing anything with the data, though, then rename the file to something other than GIF (otherwise they'll get upset they can't load the GIFs and they know it should be a GIF... then they'll get curious and try to decrypt....) _____________________________________________________________________ You don't need to buy Internet access to use free Internet e-mail. Get completely free e-mail from Juno at http://www.juno.com Or call Juno at (800) 654-JUNO [654-5866]