TELKOM NIKA , Vol.12, No .3, Septembe r 2014, pp. 6 51~656   ISSN: 1693-6 930,  accredited  A  by DIKTI, De cree No: 58/DIK T I/Kep/2013   DOI :  10.12928/TELKOMNIKA.v12i3.83    651      Re cei v ed Ma rch 2 9  201 4; Re vised July   24, 2014; Accepted Augu st  10, 2014   The Implementation of Henon Map Algorithm  for Digital Imag e Encryption      Edi Sukirman 1  , Sur y adi   MT *2  , M. Ag us Mubarak Jurusan Siste m  Informasi, Universit a s Gun adarm a , Depo k 1642 4, Indon esia   Departeme n Matematika, U n iversit a s Indo nesi a , Dep o k 1 642 4, Indon esi a   Jurusan T e knik Informati ka, Univers i tas Gu nad arma, Dep o k 164 24, Indo nesi a   *Corres p o ndi n g  author, em ail :   yadi.mt@sc i.ui.ac . id      A b st r a ct     Security infor m ati on  is a v e r y  importa nt as pect t hat  must  be n o tice d. Informatio n  not  o n ly i n  the   form  of text bu t also i n  for m   of data  i m ag e.  Usin d a ta e n c riptio n to se n d  priv ate i n for m ati on  hav e b een   w i dely us e. Bu t still n eed  to i m pr ove th en dura n ce fro m   bruto forc e att a ck. One w a ys  to i m pr ove  it, is by   usin g cha o s th eory w i th hen om  alg o rith m.  T e st resu lt ga ve the al gh orit m ca n encry pt image  data fr om  graysca le typ e  to colorfull  type. Encryption an desc r yption ti me  prop ortion al to  the si z e  i m age.   Co mp ositio n and variety cou l or does n t effect  the time. this alg o rith m has key space  of  10   and key  sensitivity up  t o   10  . So, it can  be co nclu de d that, the al gorit hm  is very d i fficult to be cr ac ked by  brute   force attack.     Ke y w ords : en cryption a l gor ih tm, chaos, di git a l i m a ge, he no n ma p       1. Introduc tion      No w a days using  comp uters to sen d  any kind s of information  thorou g h  internet   con n e c tion a r e commo n. By using p ublic p a th p eople from  arou nd the  worl d can send   informatio n e v en though it has very lo w safety level.      Information  secu rity is a n  asp e ct th at  is ve ry imp o rtant a nd u r gent to  be  notice d .   Information o n  con c e r nin g  the interest s o f  privat e, insti t utional and  corpo r ate  ne cessarily h a ve  a   high value a n d  sho u ld be  kept confid enti a l. Confid e n tial informatio n  must be in g r eat dema nd for  variou s pu rpo s e s  an d mu st carefully gua rded  T h is i n formatio n not  only in the form of text data,   but also in th e form of ima ge data that is highly confi dential.   By encryptin g data so th at only the reci pi ent ca n  only decryp t  the data is one of  s o lutions  that many enggineers    do. Some enc r yption algorithms   s u c h  as   DES ,  AES, RSA,  and  others have been   wi dely use d   to en crypt  the  im a g e  data,  but t hese al gorith m still mu st  be   impr oved durability of var i ous  attacks , s u c h  as   brute for c attack s  [1]. Many r e s e ar c h   have been  done in ho to improve th e dura b ility of the algor ith m s used in the en cryption  process fro m  a  brute force  attack, provide a good  combi nati on  of speed, hi gh se cu rity,  compl e xity,  and  c o mputational power, etc [2],[3].  One of them  is  us ing the  c h aos  theory . Chaos - based  encryption al so be en extensively  studie d  by rese archers be cau s e   of its superi o r in safety a n d   compl e xity [4]. One  algo rithm  whi c impleme n ts t he the o ry of  ch ao s i s  th e Heno n ma p   algorith m , this al gorithm  i m pleme n ts  chao s t heo ry  by gene ratin g  ra ndom  nu mbers  with t w o   initial values. The algo rithm  implement s the ch ao s th e o ry that has  sensitivity to small cha nge s in   initial para m e t er values  an d has a hi gh l e vel of  s e curity from brute forc e attack s   [5]-[11].  Based  on the  above expla nation, this  rese ar ch i s  ab out impleme n t ing the algo rithm on  the Hen on m ap for the en cryption and d e cryptio n  of digital image s informatio n.      2. Rese arch  Metho d   Cha o s th eory come s fro m  the theo ry of sy stem that exhibit irre gula r  ap p eara n ce,   despite the fact that this theory is u s e d  to ex plain the occu rre nce of r andom  data. Inventor of  cha o s th eory  is a mete oro l ogist, Edward Lorent z, in  1960  whe n  h e  made  a m odel of weat her  forecast s.by Iterating weat her math ema t ical model  to  obtain weath e r fore ca sts i n  the future. The  longe r time weath e r fore ca sts  are co mputed, the longe r iterat i on to be do ne. By chan ging  Evaluation Warning : The document was created with Spire.PDF for Python.
                          ISSN: 16 93-6 930   TELKOM NIKA   Vol. 12, No. 3, September 20 14:  65 1 – 656   652 slightly the i n itial value o f  0.00012 7 iteration   only,  he foun d th at the weath e r forecast  h ad  gene rated g r eat diverge n ce [12].  Hen on equ ation is a dynamic sy stem  t hat implements a discrete system. Hen o n   equation usi n g a point (x,y) in  an equation and mapped to a new point with the equation [9],[13]:      1 ,   (1)          (2)     Stages in u s i ng He non e q uation is divi ded into  two  stage s, whi c h are  key stream and   encryption/de cryption stag e.  In the key stream g ene rati on ph ase is  done  by usi n g algo rithm s   Hen on ma p,  the two  keys are requ ired to  be  alg o rithm s  g ene rate serie s   of  numbe rs of p s eu do-ra ndo m re al nu mb ers,   so that  seq u ence num be rs can b e  u s ed a s  a  key  stre am, the n  these nu m bers mu st be   conve r ted to an intege r array with a ran ge between 0  to 255.  The p r o c e s s is d one  by absolut  seq uen ce n u mb ers (Xn ) , ea ch of th ese  numbe rs  multiplied by  1000. M a the m atically the  integer  co nv e r sio n  fun c tion s can b e  writ ten as foll ows:  the pro c e ss i s  done by ab solut seque n c e num bers  (Xn), each of these n u mbe r s multiplie d by  1000. Mathe m atically the integer  conve r si on fun c tion s can be  writte n as follo ws:     1000         Then the ro undin g  do wn  (floor) re sul t ing in teger  (Fn). Havin g  obtaine d the  integer  seri es, the  se ries i s  ma ppe d to the ran g e  [0,  255]. Mathematically, the mappi ng  function  can  be   written as  follows   K n  = F n  m od 256      Encrptyon st age i s  the  sta ge w here the  origin al imag e or pl ain im age (P n) i s  converte d   into cip her im age (Cn )  by  XOR the pixe ls of plai n im age (P n) of t he keystre a m  (Kn)  whi c h h a been raised. Mathemati c al ly this encrypt i on functio n  can be written as follo ws:     C n  =  P n     K n   (3)     whe r e :  C n   : Ciphe r im age (e ncrypti on image ).   P n  : Plain image (p reviou s i m age ).  K n   : Keys tream.   The  de crypti on p h a s e  ha s the   same   pro c e s with  en cryptio n   stage, it's ju st usi n g  a  ciph er en cryp ted  imag e ( C n ) a s  the i npu t image. T o  d e crypt th e o r i g inal im age   f r om th ciph er  image ( C n ), b y  XOR opera t ion for  the pixel-pixel ima ge cip her  ( C n ) of the keyst r eam  ( K n ) whi c h   has b een raised. The process ca n be d e scrib ed by the algo rithm  sho w n in Fig u re 1.       Algorithm  Henon map  Initial state  : orginal image (P)  Final state  : encrypted image (C)  Input  Key A, B  Input  Image P(1..mxn)  Initial value  x(0), y(0)  Loop  i = 0  to  (mxn)-1    x(i+1) = y(i)+1-a*x(i)*x(i)    y(i+1) = b*x(i)    E(i+1) = |x(i+1)|*10000    F(i+1) = floor(E(i+1))    K(i+1) = mod(F(i+1), 256)    C(i+1) = P(i+1)  K(i+1)   Next loop  Output  Image C(1..mxn)    Figure 1. Image Encryption  Algorithm   Evaluation Warning : The document was created with Spire.PDF for Python.
TELKOM NIKA   ISSN:  1693-6 930       The Im plem e n tation of He non Map Alg o rithm  for Dig i tal Im age En cryption  (Edi Sukirm an 653 3. Results a nd Analy s is  Implementati on of the app lication i s  do ne on a  com puter  with ha rdware sp ecs: Intel ®  Core ™  pro c e s sor B 940  (2.0G H z, 2 M B L3  ca ch e), DDR3  RAM (2GB ),  VGA Intel ®  HD   Grap hics, 32 0 GB HDD, monitor, keyb o a rd an d mou s e.  In the test p hase, the en cryption  and  decry ption p r oce s s u s e a  numbe rs of  image s.   Images d a ta use d  in this st udy can b e  seen in Tabl e 1.    Table 1. Imag e Data Te stin g   File Na me   Origi n al Im age   Image  T y p e   File Size   Image Size   Clock. bmp      G r ay  scale  (8 bits/ pixel)    192 kb  256 x 2 5 6   Aerial. bmp    G r ay  scale  (8 bits/ pixel)    768 kb  512 x 5 1 2   Airport. bmp     G r ay  scale  (8 bits/ pixel)    300 kb  1024 x  1024   Gi rl .bmp     Color   (24 bits/ pixel)     192 kb  256 x 2 5 6   Lena. bmp     Color   (24 bits/ pixel)     768 kb  512 x 5 1 2   SteelSea. bmp         Color   (24 bits/ pixel)     300 kb  1024 x  1024       3.1. Analy s is  of Ke y  Space      Key spa c e i s  the total nu mber  of diffe rent  keys th a t  can  be u s e d  for e n crypti on an decryption. T o  de al  with  brute  force  at tack,  cryptog r aphi c al gorith m sh ould  ha ve a l a rg ke spa c e, then the longe r the  time it  takes  to brea k the lock of the algorithm. Key param eters used   in the en cryption alg o rithm  are t w o, na m e ly key A an d  key B, ea ch  data in d oubl e type. Do ubl e- prec is ion computing for prec is ion acc o rding  to s t andard 64-bit IEEE floating-point is  10 -15 . So  the numbe r o f  possi ble values  of each key is 10 -15 , th en the possib l e combi natio ns of two key s   k e y is  R  (A, B) =  10 -15  × 10 -1 5  =  10 30   Time requi re d to try all  co mbination s   of ke y s  (exhau stive key sea r ch ) [1 4] can  be  see n   in Table 2.     Table 2. Time  Requi red to  Try exhau stive Key Search   Ke y  Space   Experime nts/s e c   Time need ed   Secon d  Years  10 30   10 6  10 24   3,215 × 10 16   10 12  10 18  321502057 61   10 18  10 12  32150,2057 6   10 24  10 6  0,03215020 6     Evaluation Warning : The document was created with Spire.PDF for Python.
                          ISSN: 16 93-6 930   TELKOM NIKA   Vol. 12, No. 3, September 20 14:  65 1 – 656   654 Data in  Tabl e 2  sho w s that  it take approximatel y 3.215  × 1 0 16  years to  try all   combi nations of keys  with a co mputer  that can do  1 million expe riments per  second. So it is   kno w n th at it take s sub s ta ntial time to solve two  key  combi nation t hat led to  a b r ute force  attack  is not efficient       3.2. Image Similarit y  Analy s is  Testing i s  do ne by com p a r ing the ima g e   of the begi nning of the  encrypted im age an decrypted im age on a n u m ber of test im age s.  The re sults are  sho w n in Table 3.     Table 3. Re sult Test Similarity Image     Image na me     Origi n al Im age   Encr y p ti on i m a g   Descr y p tio n  im age    Clock.bmp  256 x 2 5 6       192 kb      192 kb      192 kb  Aerial.bmp  512 x 5 1 2     768 kb    768 kb    768 kb  Airport.bmp   1024 x  1024     3000 kb    3000 kb    3000 kb  Gi rl .bmp   256 x 2 5 6     192 kb    192 kb    192 kb  Lena.bmp   512 x 5 1 2     768 kb    768 kb    768 kb  Steel Sea.bmp   1024 x  1024     3000 kb    3000 kb    3000 kb      Tabel  3  sh ows that  the file  si ze  and  dim ens i o n s  of th e o r iginal  ima ge,en crypted   imag e   and d e crypte d imag e is e s sentially the  sam e  a s  the  en cryption  a nd de cryption  pro c e s s in t h is  study only ch ange the valu es  of the pixels of t he imag e usin g XOR  operation s  for key bits wit h   image pixel s     3.3. Anal y s is  of Parameter Sensitivit y   Ke y   The test is p e rform ed by comp ari ng th e im age of the de cryption  on a numbe r of test   image s that  have be en e n crypte d with  a key valu of 1.4 and  value of 0.3  B key with  very  small  ch ang e  of value  on  one  or two  key pi eces Re sults of te sting  don e b y  the de cryption   pro c e ss  uses a different  key value, ke y A with a value 1.4  + 1 0 -16 , whose result s app ea r in    Table 4.               Evaluation Warning : The document was created with Spire.PDF for Python.
TELKOM NIKA   ISSN:  1693-6 930       The Im plem e n tation of He non Map Alg o rithm  for Dig i tal Im age En cryption  (Edi Sukirm an 655 Table 4. Key Sentitivity Te st Re sult   Image na mes   E n c r y p t i o n  im ag Ke y  A =   1.4   Ke y   B = 0.3   Descr y p tio n  im age   ke y   A   = 1.4 + 10 -1 6   ke y   B = 0.3   Descr y p tio n  im age   Ke y   A   = 1.4 = 1. 4 + 10 -1 7   ke y   B = 0.3   Clock.bmp         Aerial.bmp            Airport.bmp          Gi rl .bmp            Lena.bmp             Steel Sea.bmp                Table 4, sho w s the p r o c e ss of de cryption of  the encrypted imag e  with little different in   one of the ke y, encryption  algorith m   ha s key sen s itivity that reache 10  .       3.4. Analy s is  Process En cr y p tion and Decr y p tion Time  The test i s  pe rforme d by calcul ating the   pro c e ss tim e  of encryption  and d e cryption on  a   numbe r of test images. The  test results shown in Tabl e 5.    Table 5. Time  Test Re sult for Encryption  and De crypti on Pro c e s Image na me   Image t y p e      File  size   Image  dime nsio ns   (pixel )   Encr y p ti on tim e   proces   (sec ond Descr y p tio n   time proces  (seco nd )   Clock.bmp  G r ay scale   (8 bits/ pixel)  192 kb  256 x 2 5 6   2.684   2.638   Aerial.bmp  G r ay scale   (8 bits/ pixel)  768 kb  512 x 5 1 2   40.867   40.613   Airport.bmp   G r ay scale   (8 bits/ pixel)  300 kb  1024 x  1024   866.170   816.802   Gi rl .bmp   Color   (24 bits/pixel)   192 kb  256 x 2 5 6   2.653   2.649   Lena.bmp   Color   (24 bits/pixel)   768 kb  512 x 5 1 2   40.725   40.587   Steel Sea.bmp   Color   (24 bits/pixel)   300 kb  1024 x  1024   884.054   848.692   Evaluation Warning : The document was created with Spire.PDF for Python.
                          ISSN: 16 93-6 930   TELKOM NIKA   Vol. 12, No. 3, September 20 14:  65 1 – 656   656 Test  result d a ta in Ta ble  5, sho w s that  the en crypti on an d de cryption p r o c e s sing time   prop ortio nal t o  the  size  of the ima ge dim ensi o n s , the  greate r  the  di mensi o n s  of  an ima ge of t he  longe r time re quire d to en crypt the image . Table  5 al so  sho w s th at the co mpo s iti on and  diversity  of colo rs tha t  make  up t he ima ge di d not  si gnifi cantly affect  time imag e  encryption  and   decryption p r oce s s.      4. Conclusio n   Hen on m a p   algorith m  im plementatio n  on  the  pro c ess of  en cry p tion a nd  de cryption  of  digital  imag e has bee succe ssfully ca rri ed  out on  the  appli c ation  a nd teste d  o n   several ima g e s.  The experi m ental re sults sho w   th at  th alg o rithm  Hen on map  can   en crypt and de crypt  i m age   with exactly the sam e  as t he origi nal im age,  and  can  be ded uced from this stu d y that :    a.  Encryptio n  a nd de cryptio n  pro c e ssi ng ti me propo rtio nal to the si ze of the imag e dimen s io ns,  the greater the dim e n s ion s  of a n  ima g e  of t he l ong er time  re qui red to  en cry p t the ima g e   becau se the  bigger the  dimen s ion s   of the image , the bigger  pixels of the  image to be   pro c e s sed an d vice versa.  b.  Comp ositio n and diversity of colors of  image di d n o t signifi cantly affect the time  of encryptio n   and de cryptio n  pro c e s ses.  t the image which h a s the  comp ositio n and diversity of high col o with the  ima ge that  ha s t he  comp ositi on a nd  diversity of  l o colo r h a s tim e  en cryption  proc es s  is  relatively the s a me.  c.  Encryptio n  al gorithm h a s   key sp ace for  10   and key se nsitivity that reache 10  , s o  the   algorith m  is very difficult to be cra c ked b y  brute force attack.   Thus the  digit a l imag e e n cryption algo rit h m is  very dif f icult to b e   so lved with  brute force  at t a ck s.       Referen ces   [1]  Pareek  NK., Patidar V., Su KK. Image e n c r y p ti on  usin g c haotic  log i stic  map.  Jour nal  o f  Imag e an Visio n  Co mp uti ng.  200 6; 24: 9 26-9 34.   [2]  Patidar V., Pareek NK., Sud KK.  A n e w  s ubtitutio n-diffus i on  bas ed  ima ge c i ph er us in g ch aoti c   standar d an l ogistic ma p s.  Journ a l of Co mmu n  No nli n e a r Sci Nu mer Si mulat. , 200 9; 14: 3056- 30 75.   [3]  Menez es, Alfre d  J., Paul  C v an Oorsch ot, Scott A. Vanstone. H a n dbo o k  of App lie d C r y p to gra p h y .   CRC Press. 19 96.   [4]  Z hang  W ., W ong K., Yu  H., Z hu Z .  An  ima g e  encr y pt ion  sch eme  usin g rev e rse  2-dim ensi ona l ch aoti c   map a nd  dep e nde nt diffusi on Journa l of C o mmun N o n lin ear Sci  Nu mer  Simulat.  2 0 1 3 ;  18: 206 6- 208 0.  [5]  Kocarev L., Lian S.  Chaos-b a s ed cyrptogr ap hy . Berlin H e id elb e rg: Sprin g e r-Verlag. 2 011.   [6]  Gao H., Z h a n g  Y., Lia ng S.,  Li D. A  n e w  c h aotic  alg o rithm  for ima g e  enc r y pti on.  J ourn a l  of C h a o s,   Soluto ns an d F r actals.  200 6; 29: 393- 39 9.  [7] Sury adi  MT New  Cha o tic Algorit h m  for Vide o Encrypti on.   4 th  T he Internati o n a l S y mp osi u m o n   Cha o s Revo luti on in Sci enc e, T e chnolog an Societ y 20 13 , Jakarta, 28-2 9 , August. 201 3.  [8]  Munir, R i n a ld i., Algor itma E n k r ipsi S e l e ktif Ci tra Dig ital  Dal a m Ran a h  F r ek uens i Ber basis  Permutasi   Chaos.  Jurnal Rekay a sa  Elek trika . 2012; 1 0 ( 2 ): 69-75.   [9]  Abu Zaid, Osama M., El-Fisha w y Na w a l A.,  Nig m, EM. Cr ypt o s y stem Al gorithm B a se d  on C h a o tic  S y stem for En cr y p ti ng C o lor ed Image.  Int e rnati ona l Jou r nal of Co mpu t er Science Is sues.  201 3;   10(4): 21 5-2 2 4 .   [10]  Z hang Y. P l a i nte x t Re late d  Image  E n cr ypti on Sc hem e Usi ng  Cha o tic Map.  TE LKOMNIKA  Indon esi an Jou r nal of Electric al Eng i ne eri ng.  2014; 1 2 (1): 6 35-6 43.   [11]  Z hang  Y, Xia  JL, Cai  P, Ch en B. Pl aint e x t rela te d t w o- le vel secr et ke imag e e n cr ypti on sch eme .   T E LKOMNIKA Indon esi an Jou r nal of Electric al Eng i ne eri n g .  2012; 1 0 (6): 1 254- 126 2.   [12] Deva ne R L An intro ductio n  to chaotic dy na mic a l syste m s  (2 nd   ed.). Ne w  York: Ad diso n-W e sle y     Publ ishi ng com pan y, Inc. 198 9.  [13]  Sonis M. Onc e  more  on  Hé non m ap: A n a l y s is of  bifurca t ions.  Ch aos,  Solito n s & Fra c tals . 19 96 ;   7(12): 22 15 –22 34.   [14] Stalli ngs  W .   C o mputer  an Netw ork Secur i ty : Princip l and Pr actice  (5 th  ed.). Ne w   York: Prentic e   h a l l .  20 11 Evaluation Warning : The document was created with Spire.PDF for Python.