2
2
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
3
3
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
4
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en" dir="ltr">
6
<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
6
7
<meta name="verify-v1" content="g222frIIxcQTrvDR3NBRUSKP3AnMNoqxOkIniCEkV7U=" />
7
8
<link rel="meta" type="application/rdf+xml" title="ICI" href="http://imagemagick.org/ici.rdf" />
8
<style type="text/css" media="screen,projection"><!--
9
<style type="text/css" media="all">
9
10
@import url("../www/magick.css");
11
12
<link rel="shortcut icon" href="../images/wand.ico" type="images/vnd.microsoft.icon"/>
12
13
<title>ImageMagick: Encipher or Decipher an Image</title>
13
14
<meta http-equiv="Content-Language" content="en-US"/>
45
46
<div class="eastbar">
48
<a href="../index.html">About ImageMagick</a>
50
<div class="sep"></div>
52
<a href="../www/command-line-tools.html">Command-line Tools</a>
55
<a href="../www/command-line-processing.html">Processing</a>
58
<a href="../www/command-line-options.html">Options</a>
61
<a href="http://www.imagemagick.org/Usage/">Usage</a>
64
<a href="../www/api.html">Program Interfaces</a>
67
<a href="../www/magick-wand.html">MagickWand</a>
70
<a href="../www/magick-core.html">MagickCore</a>
73
<a href="../www/perl-magick.html">PerlMagick</a>
76
<a href="../Magick++/">Magick++</a>
79
<a href="../www/architecture.html">Architecture</a>
49
<a title="About ImageMagick" href="../index.html">About ImageMagick</a>
51
<div class="sep"></div>
53
<a title="Binary Releases" href="../www/binary-releases.html">Binary Releases</a>
56
<a title="Binary Release: Unix" href="../www/binary-releases.html#unix">Unix</a>
59
<a title="Binary Release: MacOS X" href="../www/binary-releases.html#macosx">Mac OS X</a>
62
<a title="Binary Release: Windows" href="../www/binary-releases.html#windows">Windows</a>
64
<div class="sep"></div>
66
<a title="Command-line Tools" href="../www/command-line-tools.html">Command-line Tools</a>
69
<a title="Command-line Tools: Processing" href="../www/command-line-processing.html">Processing</a>
72
<a title="Command-line Tools: Options" href="../www/command-line-options.html">Options</a>
75
<a title="Command-line Tools: Usage" href="http://www.imagemagick.org/Usage/">Usage</a>
78
<a title="Program Interfaces" href="../www/api.html">Program Interfaces</a>
81
<a title="Program Interface: MagickWand" href="../www/magick-wand.html">MagickWand</a>
84
<a title="Program Interface: MagickCore" href="../www/magick-core.html">MagickCore</a>
87
<a title="Program Interface: PerlMagick" href="../www/perl-magick.html">PerlMagick</a>
90
<a title="Program Interface: Magick++" href="../Magick++/">Magick++</a>
81
92
<div class="sep"></div>
83
<a href="../www/install-source.html">Install from Source</a>
86
<a href="../www/install-source.html#unix">Unix</a>
89
<a href="../www/install-source.html#windows">Windows</a>
94
<a title="Install from Source" href="../www/install-source.html">Install from Source</a>
97
<a title="Install from Source: Unix" href="../www/install-source.html#unix">Unix</a>
100
<a title="Install from Source: Windows" href="../www/install-source.html#windows">Windows</a>
91
102
<div class="menu">
92
<a href="../www/binary-releases.html">Binary Releases</a>
95
<a href="../www/binary-releases.html#unix">Unix</a>
98
<a href="../www/binary-releases.html#macosx">Mac OS X</a>
101
<a href="../www/binary-releases.html#windows">Windows</a>
104
<a href="../www/resources.html">Resources</a>
106
<div class="sep"></div>
108
<a href="../www/download.html">Download</a>
110
<div class="sep"></div>
112
<a href="http://www.imagemagick.org/script/search.php">Search</a>
114
<div class="sep"></div>
116
<a href="../www/sitemap.html">Site Map</a>
103
<a title="Resources" href="../www/resources.html">Resources</a>
106
<a title="Architecture" href="../www/architecture.html">Architecture</a>
109
<a title="Download" href="../www/download.html">Download</a>
111
<div class="sep"></div>
113
<a title="Search" href="http://www.imagemagick.org/script/search.php">Search</a>
115
<div class="sep"></div>
117
<a title="Site Map"href="../www/sitemap.html">Site Map</a>
118
119
<div class="sub">
119
<a href="../www/links.html">Links</a>
120
<a title="Site Map: Links"href="../www/links.html">Links</a>
121
122
<div class="sep"></div>
122
123
<div class="menu">
123
<a href="../www/sponsors.html">Sponsors:</a>
124
<a title="Sponsors" href="../www/sponsors.html">Sponsors:</a>
125
126
<div class="sponsbox">
126
127
<div class="sponsor">
127
<a href="http://www.online-kredit-index.de">Kredit</a><!-- 201004010120 Buchhorn -->
129
<div class="sponsor">
130
<a href="http://www.blumenversender.com">Blumenversand</a><!-- 201005010120 -->
132
<div class="sponsor">
133
<a href="http://www.print24.de/">Druckerei</a><!-- 201009010720 -->
135
<div class="sponsor">
136
<a href="http://www.goyax.de">Börse</a><!-- 201001000240 Gewiese digital-finance.de -->
138
<div class="sponsor">
139
<a href="http://www.allesdruck.de">Druckerei Online</a><!-- 201012001200 allesdruck.de-->
141
<div class="sponsor">
142
<a href="http://www.who-sells-it.com/">Free Catalogs</a><!-- 201002010000 -->
128
<a title="Sponsor: Webdesign Agentur" href="http://www.ventzke-partner.de">Webdesign Agentur</a><!-- 201101010480 invendio.de-->
130
<div class="sponsor">
131
<a title="Sponsor: LVM Versicherung" href="http://www.neu-reich.de">LVM Versicherung</a><!-- 201101010480 -->
133
<div class="sponsor">
134
<a title="Sponsor: Deko.net" href="http://www.deko.net">Deko.net</a><!-- 201101010600 Peterssen-->
136
<div class="sponsor">
137
<a title="Sponsor: Kredit" href="http://www.online-kredit-index.de">Kredit</a><!-- 201007010120 Buchhorn -->
139
<div class="sponsor">
140
<a title="Sponsor: Druckerei" href="http://www.print24.de/">Druckerei</a><!-- 201009010720 -->
142
<div class="sponsor">
143
<a title="Sponsor: Druckerei Online" href="http://www.allesdruck.de">Druckerei Online</a><!-- 201012011200 allesdruck.de-->
145
<div class="sponsor">
146
<a title="Sponsor: Online-Magazin" href="http://www.unkostenbeitrag.de/" title="Online-Magazin">Online-Magazin</a><!-- 20101101000200 -->
154
158
<h2><a name="intro"></a>Introduction to Enciphering and Deciphering Images</h2>
155
159
<div class="doc-section">
157
<p>Most images, by design, are made to be viewed often and by many people. Web images, for example, may be viewed hundreds of times a day by a multitude of web vistors. However, in some cases, you may want to keep a particular image private so that only you or perhaps a select group of your friends or web visitors can view it. ImageMagick permits you to scramble your images such that unless someone knows your secret key, they will be unable to view the original content.</p>
161
<p>Most images, by design, are made to be viewed often and by many people. Web images, for example, may be viewed hundreds of times a day by a multitude of web vistors. However, in some cases, you may want to keep a particular image private so that only you or perhaps a select group of your friends or web visitors can view it. ImageMagick permits you to scramble your images such that unless someone knows your passphrase, they will be unable to view the original content.</p>
159
163
<p>You could use an <a href="http://www.wizards-toolkit.org/www/encipher.html">enciphering</a> utility to scramble your image but they typically scramble the entire file making it unrecognizable as an image format. With ImageMagick, only the pixels are scrambled. The scrambled image continues to be recognized as an image and will even display in your web page. However, the content appears as gibberish, nothing like the original content.</p>
163
167
<h2><a name="encipher"></a>Encipher an Image</h2>
164
168
<div class="doc-section">
166
<p>Use the <a href="../www/command-line-options.html#encipher">-encipher</a> option to scramble your image so that it is unrecognizable. The option requires a filename that contains your secret key. In this example we scramble an image and save it in the PNG format:</p>
170
<p>Use the <a href="../www/command-line-options.html#encipher">-encipher</a> option to scramble your image so that it is unrecognizable. The option requires a filename that contains your passphrase. In this example we scramble an image and save it in the PNG format:</p>
168
<p class='crt'><span class="crtprompt"> $magick> </span><span class='crtin'>convert rose.jpg -encipher passkey.txt rose.png</span></p>
169
<p>Here we encipher an image using another image as the passkey:</p>
172
<p class='crt'><span class="crtprompt"> $magick> </span><span class='crtin'>convert rose.jpg -encipher passphrase.txt rose.png</span></p>
173
<p>Here we encipher an image using another image as the passphrase:</p>
171
175
<p class='crt'><span class="crtprompt"> $magick> </span><span class='crtin'>convert rose.jpg -encipher smiley.gif rose.png</span></p>
185
189
<p>Some formats do not support enciphered pixels-- the JPEG or GIF format, for example. To ensure your image format is supported, encipher a test image and verify you can restore its original content <em>before</em> you encipher any additional images in that format.</p>
187
<p>The passkey can be any combinations of letters and symbols. It should be a minimum of 12 character combinations to ensure your image remains private. Also make sure your passkey file permissions prevent others from reading it otherwise unintended users may be able to view the original image content.</p>
191
<p>The passphrase can be any combinations of letters and symbols. It should be a minimum of 12 character combinations to help ensure your image remains private. Also make sure your passphrase file permissions prevent others from reading it otherwise unintended users may be able to view the original image content.</p>
189
<p>You can only restore the original image content if you know your passkey. If you lose or forget it, your original image content is lost forever.</p>
193
<p>You can only restore the original image content if you know your passphrase. If you lose or forget it, your original image content is lost forever.</p>
191
195
<p>ImageMagick only scrambles the image pixels. The image metadata remains untouched and readable by anyone with access to the image file.</p>
193
<p>ImageMagick uses the <a href="http://en.wikipedia.org/wiki/Advanced_Encryption_Standard">AES</a> cipher in cipher feedback mode. We use the passkey to derive the cipher key and the required nonce.</p>
197
<p>ImageMagick uses the <a href="http://en.wikipedia.org/wiki/Advanced_Encryption_Standard">AES</a> cipher in cipher feedback mode. We use the passphrase to derive the cipher key and the required nonce.</p>
195
199
<p>Currently only ImageMagick can restore your enciphered image content. We use a standard cipher and mode so other vendors are encouraged to support enciphered image content.</p>
200
205
<div id="linkbar">
201
206
<!-- <span id="linkbar-west"> </span> -->
202
207
<span id="linkbar-center">
203
208
<a href="http://www.imagemagick.org/discourse-server/">Discourse Server</a> •
204
<a href="../www/mailing-list.html">Mailing Lists</a> •
205
209
<a href="http://www.imagemagick.org/MagickStudio/scripts/MagickStudio.cgi">Studio</a>
207
211
<span id="linkbar-east"> </span>
209
213
<div class="footer">
210
<span id="footer-west">© 1999-2009 ImageMagick Studio LLC</span>
214
<span id="footer-west">© 1999-2010 ImageMagick Studio LLC</span>
211
215
<span id="footer-east"> <a href="http://www.imagemagick.org/script/contact.php">Contact the Wizards</a></span>
213
217
<div style="clear: both; margin: 0; width: 100%; "></div>