An LSB Data Hdng Technque Usng Prme Numbers Sandan Dey (), Aj Abraham (), Sugata Sanya (3) Anshn Software Prvate Lmted, Kokata 79 Centre for Quantfabe Quaty of Servce n Communcaton Systems Norwegan Unversty of Scence and Technoogy, Norway 3 Schoo of Technoogy and Comuter Scence, Tata Insttute of Fundamenta Research, Inda sandandey@gmacom, ajabraham@eeeorg, sanya@tfrresn Abstract In s aer, a nove data hdng technque s roosed, as an mrovement over e Fbonacc LSB data-hdng technque roosed by Battst et a [] Frst we maematcay mode and generaze our aroach Then we roose our nove technque, based on decomoston of a number (xe-vaue) n sum of rme numbers The artcuar reresentaton generates a dfferent set of (vrtua) bt-anes atogeer, sutabe for embeddng uroses They not ony aow one to embed secret message n hgher btanes but aso do t wout much dstorton, w a much better stego-mage quaty, and n a reabe and secured manner, guaranteeng effcent retreva of secret message A comaratve erformance study between e cassca Least Sgnfcant Bt (LSB) meod, e Fbonacc LSB data-hdng technque and our roosed schemes has been done Anayss ndcates at mage quaty of e stego-mage hdden by e technque usng Fbonacc decomoston mroves aganst at usng sme LSB substtuton meod, whe e same usng e rme decomoston meod mroves drastcay aganst at usng Fbonacc decomoston technque Exermenta resuts show at, e stego-mage s vsuay ndstngushabe from e orgna cover-mage Introducton Data hdng technque s a new knd of secret communcaton technoogy Whe crytograhy scrambes e message so at t can t be understood, steganograhy hdes e data so at t can t be observed In s aer, we dscuss about a new decomoston meod for cassca LSB data-hdng technque, n order to make e technque more secure and hence ess redctabe We generate a new set of (vrtua) bt anes usng our decomoston technque and embed data bt n ese bt anes Fbonacc LSB Data Hdng Technque The am of s artcuar technque (roosed by Battst et a) s to nvestgate decomoston nto dfferent bt-anes, based on Fbonacc -sequences, F () = F () = F ( n) = F ( n ) F ( n ), n, n Ν and embed a secret message-bt nto a xe f t asses e Zeckendorf condton, en durng extracton, foow e reverse rocedure 3 A Generazed LSB Data Hdng and e Prme Decomoston Technque Fgure Generazed data-hdng technque If we have k-bt cover mage, ony k bt-anes are avaabe to embed secret data Dstorton ncreases exonentay w ncreasng bt-ane, t becomes mossbe to embed data n hgher bt-anes So, our rmary target here s to ncrease e tota number of avaabe (and embeddabe) bt anes wout much dstorton To do s, we try to fnd a functon f at ncreases e number of bt-anes (for a k-bt mage) from k to n, n k, by convertng to some oer bnary number system w dfferent weghts, ensurng at number of bts taken to reresent e
same xe s greater an at of cassca bnary (ese extra bt-anes are referred to as vrtua bt-anes), aso ensurng ess abrut change n xe vaue w ncreasng bt ane It aows hgher (vrtua) bt anes to be used to embed data w much ess dstorton Fgures and exan s concet Fgure Iustraton of embeddng secret data-bt 3 The Number System We defne a number system by defnng: A constant, caed base or radx r (dgts of e,, r number system { } A functon, caed weght functon W (), where W () denotes weght corresondng to bt, Hence, e ar ( r, W ()) defnes a number system cometey A number havng reresentaton dk dk dd n number system ( r, W ()) w have k vaue D = d W ( ), where, d {,,, k } n decma Aso, we may have more an one reresentaton for e same number n our number system, we must be abe to emnate s redundancy and reresent one number unquey We use e foowng strategy - from mute reresentatons of e same vaue, choose e one w excograhca hghest vaue, dscard a oers For cassca bnary number system, we have, W () = ( ) W : W ( ) =, Z { } corresondng to a, number (e xe-vaue) k k C = b bt-ane ( LSB = bt) A k-bt, where, b k s reresented as, C {,} Now, f converts / s k to some vrtua xe n w n (vrtua) btanes, n k, to exand number of bt anes To fnd such an f s equvaent to fndng a new weght functon (), e, W ( ), {,, n } W, so at W () denotes weght of vrtua bt-ane n e new / / / = b W ( ), b,, number system { } n C our new decomoston, satsfyng ' ) = ( k () (, ) n (, w()) Aso, W () must have ess abrut changes w resect to ncreasng an at n case of Moreover, we must ensure at e functon f must be njectve, e, nvertbe, oerwse we sha not be abe to extract e embedded message recsey 3 Number System Usng Fbonacc -Sequence Decomoston The weght functon roosed by Battst et a s, n N, e, W () = Fb (), number system to F n mode vrtua bt-anes s, F ()) To ensure ( nvertbty, nstead of Zeckendorf s eorem, we refer to use excograhcay hgher roerty n case of Fbonacc as we, smar to what we sha use n case of our rme decomoston technque Fgure 3 Fbonacc (-sequence) decomoston for 8-bt mage yedng vrtua bt-anes 33 Proosed Prme Number Decomoston We defne a new number system, denoted as (, P ()), where e weght functon P() s defned as: P() =, P( ) =, Z, = =, =, = 3, 3 = 5, C Pr me,
Snce e weght functon here s comosed of rme numbers, we name s number system as rme number system and e decomoston as rme decomoston If any vaue has more an one reresentaton n s number system, we aways take e excograhcay hghest of em, to assert nvertbe roerty (eg, e number 3 has dfferent reresentatons n 3-bt rme number system, namey, and, snce we have, = 3 = 3 = 3 = 3 But s excograhcay (from eft to rght) hgher an, we choose to be vad reresentaton for 3 n our rme number system and us dscard as an nvad reresentaton 3 max (,) excogahc Hence, e vad reresentatons are:,,, 3, 4, 5, 6 Now, we embed a secret data bt nto a (vrtua) btane by smy reacng e corresondng bt by e data bt, ony f we fnd at after embeddng e resutng reresentaton s a vad reresentaton n our number system, oerwse we don t embed, just sk Ths s ony to guarantee e exstence of e nverse functon and correctness for extracton of our secret embedded message bt we need to do s to fnd an n such at n k, snce e hghest number at can be reresented n n-bt rme number system s ) After fndng e rmes, we create a ma of k-bt (cassca bnary decomoston) to n-bt numbers (rme decomoston), n > k, markng a e vad reresentatons n our rme number system For an 8-bt mage, art of xe vaue vs rme decomoston ma s shown n Fgure 5 Fgure 4 Error n not guaranteeng unqueness As evdent from Fgure-4, t s cear at one shoud embed secret data bt ony to ose xes, where, after embeddng, we get a vad reresentaton n e number system 34 Embeddng Agorm Frst we fnd e set of a rme numbers at are requred to decomose a xe vaue n a k-bt covermage, e, we need to fnd a number n Ν such at a ossbe xe vaues n e range [, ] can be reresented usng frst n rmes n our n-bt rme number system, so at we get n vrtua bt-anes after decomoston Usng Godbach conjecture etc, at a xe-vaues n e range [, ] can be k m reresented n our m-bt rme number system, so a Fgure-5 Prme decomoston for 8-bt mage yedng 5 vrtua bt-anes Next, for each xe of cover mage choose a (vrtua) bt ane, say bt-ane ( < n), embed secret data bt nto at artcuar bt ane, by reacng e corresondng bt by e data bt, ff we fnd at after embeddng e data bt, e resutng sequence s a vad reresentaton n n-bt rme number system, e, exsts n e ma After embeddng e secret message bt, we convert e resutant sequence n rme number system back to ts vaue (n cassca bnary number system) and get our stego-mage The extracton agorm s exacty e reverse From stego-mage, we convert each xe w embedded data bt to ts corresondng rme decomoston and from bt-ane extract secret message bt Combne a bts to get e secret message
35 Comarson Between Standard Bnary, Fbonacc and Prme Decomoston By Tchebychef eorem [5], we have, π ( x)n( x) 9 < < 5, x, x where π (x) = number of rmes not exceedng x, whch eads to e very famous Prme Number π ( n) Theorem m = Now, from s, one can n ( n / n( n)) n show at m = n nn( n) = θ n n( n) n, f n be e n rme, A Lower Bound for e Fbonacc Numbers If α be a ostve root of e quadratc equaton 5 α α =, e, α =, t s easy to show (eg, by maematca nducton) at, F( n) > α, n >, n Ν Snce 5 36, we get, F( n) > (6834), n > We can easy generaze e above defnton of Fbonacc sequence nto Fbonacc -sequence, F () = F () = F ( n) = F ( n ) F ( n ), n, n Ν For =, we obtan Fbonacc -sequence, as defned above Smary, for oer vaues of, one can easy derve (by smar nducton) some exonenta owerbounds, and t s qute obvous at e base of e exonenta ower bound w decrease graduay w ncreasng eg, for =, f α be a ostve root of 3 e equatonα α =, sovng (eg, by Newton- Rahson) we getα = 465575, and t s easy to show by nducton at F ( n) > (465575), n >, From above, we can generaze, for Fbonacc - sequence, f α be a ostve root of e equatonα α =, we have e nequaty, F ( n) > α > α ( α ) 5 α R, α = = 6834, α = 465575, α = 3878, α = 3478, The sequence, 3, α s decreasng n 4 36 Performance Measures Mean Squared Error and SNR: We have e foowng test statstcs for erformance measures, MSE M = N = j = ( f g ) j MN L PSNR = og MSE where M and N are e number of rows and number of coumns resectvey of e cover mage, f j s e xe vaue from e cover mage, g s e xe vaue from e stego-mage, and L s e eak sgna vaue of e cover mage (for 8-bt mages, L=55) Sgna to nose rato quantfes e mercetbty, by regardng e message as e sgna and e message as e nose Here, we use a sghty dfferent test-statstc, namey, Worst-case-Mean-Square-Error (WMSE) and e corresondng PSNR (er xe) as our test-statstcs We defne WMSE as foows: If e secret data-bt s embedded n e bt ane of a xe, e worst-case error-square-er-xe ( ) W = WSE = W ( ) =, e case when e corresondng bt n cover-mage togges n stegomage, after embeddng e secret data-bt (eg, worstcase error-square-er-xe for embeddng n bt ane for a xe n cassca bnary decomoston s = = 4 If e grayscae cover-mage has sze w x h, we defne, ( W ) ) = w h WSE WMSE = w h ( Here, we try to mnmze s WMSE (hence WSE) and maxmze e corresondng PSNR, where L PSNR = og WSE 36 Proosed Prme Decomoston generates More (vrtua) Bt-anes Usng Cassca bnary decomoston, for a k-bt cover mage, we get ony k bt-anes er xe, where we can embed our secret data bt Now, we have, = θ n n( n) and n α R n n( n) = o : F n ( α ) ( n) > ( α ) drecty mes o F ( n) j j n = The maxmum (hghest) number at can be reresented n n-bt number system usng our rme decomoston s, and n case of n-bt number system usng Fbonacc -sequence decomoston
s F Now, t s easy to rove at n Ν : n n, we have, n = n F > So, usng same number of bts t s ossbe to reresent more numbers n case of rme decomoston an n case of Fbonacc - sequence decomoston, when number of bts s greater an some reshod Ths n turn mes at number of (vrtua) bt-anes generated n case of rme decomoston w be eventuay (after some n) more an e corresondng number of (vrtua) btanes generated by Fbonacc -Sequence decomoston Fgure 6 ustrates s cam 36 Prme Decomoston gves ess dstorton n hgher bt-anes Here we assume e secret message eng (n bts) s same as mage sze, for evauaton of our test-statstcs For message w dfferent eng, e same can smary be derved n a straght-forward manner In case of our Prme Decomoston, WMSE for embeddng secret message bt ony n (vrtua) btane of each xe (after exressng a xe n our rme number system, usng rme decomoston technque) =, because change n bt ane of a xe smy mes changng of e xe vaue by at most rme number From above, (treatng magesze as constant) we concude, ( WMSE ) = w h = θ( og( )) bt aneprme Decomost on whereas WMSE n case of cassca (tradtona) bnary (LSB) data hdng technque s gven by, WMSE = θ 4 bt ane Bnary Decomoston The above resut mes at e dstorton n case of rme decomoston s much ess (oynoma) an for cassca bnary (exonenta)now, et s cacuate e WMSE for e embeddng technque usng Fbonacc -sequence decomoston In s case, WMSE for embeddng secret message bt ony n (vrtua) bt-ane of each xe (exressng t usng Fbonacc--sequence decomoston) = ( F ) (), because change n bt ane of a xe mes changng of xe vaue by at most Fbonacc number For =, ( WMSE ) bt ane Fbonacc Sequence Decomost on = w h ( F ( )) ( F ( )) ) ( 68 ) = θ > θ Smary, for oer vaues of, one can easy derve (by nducton) some exonenta ower-bounds, whch are defntey better an e exonenta bound obtaned n case of cassca bnary decomoston, but st ey are exonenta n nature, even f e base of e exonenta ower bound w decrease graduay w ncreasng Generazng, we get, WMSE > θ α, bt ane Fbonacc Sequence Decomost on T 5 α R, α =, α > α, he sequence α s decreasng n Obvousy, e Fbonacc--sequence decomoston, deste beng better an cassca bnary decomoston, s st exonenta and causes muchmore dstorton n e hgher bt-anes, an our rme decomoston, n whch case WMSE s oynoma (and not exonenta!) n nature The ot shown n Fgure-6 roves our cam, t vndcates oynoma nature of e weght functon n case of rme decomoston and exonenta nature of cassca bnary and Fbonacc decomoston Fgure6 Wt functons for dfferent decomostons At a gance, e resut of our test-statstcs, ( WMSE ) = θ ( 4 ) bt ane Cassca Bnary Decomoston ( WMSE ) = θ ( og ( ) ) bt ane Pr me Decomoston ( WMSE ) = θ ( c ) ), c bt ane Fbonacc Decomoston R,68 > c > c,, w ( WMSE ) = θ ( 68) bt ane Fbonacc Decomoston
k ( ) og PSNR worst Cassca Bnary Decomost on = ( ) k ( ) og PSNR worst Pr me Decomost on =, ( c og ( ) ) k ( ) og PSNR = worst Fbonacc Decomost on, ( c ) α R, α = 68, α > β,, w k ( ) og PSNR = worst Fbonacc Decomost on 4 Exerment Resuts ( 68 ) c R We have, as nut, an 8-bt gray-eve cover mage of Lena Secret message eng = cover mage sze, (message strng sandan reeated mute tmes to f e cover mage sze)the secret message bts are embedded n chosen bt-ane The test message s hdden nto e chosen bt-ane usng e cassca bnary (LSB) technque, Fbonacc (-sequence) decomoston and Prme decomoston technque searatey and comared Fgure 7 Resuts of embeddng data n dfferent btanes usng dfferent data-hdng technques Fgure 7 ustrates at we get 8, and 5 (vrtua) bt-anes usng cassca LSB, Fbonacc and Prme decomoston data-hdng technque resectvey (hghest 5 vrtua bt-anes for Prme) Data-hdng technque usng e rme decomoston has a better erformance an at of Fbonacc decomoston, e ater beng more effcent an cassca bnary decomoston, when judged n terms of embeddng secret data bt nto hgher bt-anes causng east dstorton, ereby east chance of beng detected To embed n more an one vrtua bt-ane, one may use varabe de embeddng [] 5 Concusons Ths aer resented very sme meod of data hdng technque usng rme numbers It s shown (bo eoretcay and exermentay) at e data-hdng technque usng rme decomoston outerforms e famous LSB data hdng technque usng cassca bnary decomoston, and at usng Fbonacc - sequence decomoston We have exermented usng e famous Lena mage, but snce our eoretca dervaton ustrates at e test-statstc vaue (WMSE, PSNR) s ndeendent of e robabty mass functon of e gray eves of e nut mage, e (worst-case) resuts w be smar f we use any grayeve mage as nut, nstead of e Lena mage References [] F Battst, M Car, A Ner, K Egazaran, A Generazed Fbonacc LSB Data Hdng Technque, 3rd Internatona Conference on Comuters and Devces for Communcaton (CODEC-6), Insttute of Rado Physcs and Eectroncs, Unversty of Cacutta, December 8-, 6 [] C Shao-Hu, Y Tan-Hang, G Hong-Xun, Wen, A varabe de LSB data hdng technque n mages, Internatona Conference on Machne Learnng and Cybernetcs, 4,, Vo 7, 6-9 399 3994, 4 [3] A K Jan, Advances n maematca modes for mage rocessng, Proceedngs of e IEEE, 69(5):5 58, May 98 [4] Jessca Frdrch, Mrosav Gojan and Ru Du Detectng LSB steganograhy n coor and grayscae mages, Magazne of IEEE Mutmeda, Seca Issue on Securty, -8, [5] Teang S G, Number Theory, Tata McGraw-H, ISBN -7-4648-6, Frst Rernt, 999, 67-63