I n d on e s i an   Jo u r n al   o El e c t r i c al   En gi n e e r i n g   an d   C o m p u te r   S c i e n c e   V o l .   22 ,   N o .   1 A p r i l   2021 ,   p p.   485 ~ 4 9 6   IS S N :   25 02 - 4752 ,   D O I :   10. 1 1591 / i j e e c s . v 22 .i 1 . pp 485 - 4 9 6             485       Jou r n al   h o m e pa ge ht t p: / / i j e e c s . i a e s c or e . c om   D e si g n i n g   c o n sensu s   a l g o r i t h m   f o r   c o l l a b o r a t i v e   s i g n a t u r e - b a sed  i n t r u si o n   d e t e c t i o n   sy st e m       Ek o   A r i p   W i n an to 1 ,   M o h d   Y az i d   I d r i s 2 ,   D e r i s   S ti aw an 3   , M o h amm ad   S u l k h an   N u r fati h 4   1, 2, 4 S c h oo l   o f   C o m put i ng ,   F a c ul t y   of   E ng i ne e r i ng ,   U n i v e r s i t i   T e k no l o g i   M a l a y s i a ,   M a l a y s i a   3 D e pa r t m e n t   o f   C o m put e r   S c i e nc e ,   U n i v e r s i t a s   S r i w i j a y a ,   I ndo ne s i a       A r ti c l e   I n fo     A B S TR A C T   Ar t i c l e   h i s t or y :   R e c e i v e M a r   5 ,   20 20   R e v i s e D e c   5 ,   2 020   A c c e pt e J a n   11 ,   202 1       S i g na t u r e - ba s e c o l l a bo r a t i v e   i nt r us i o de t e c t i o s y s t e m   ( C I D S )   i s   hi g hl y   de pe n ds   o t h e   r e l i a b i l i t y   o f   n o de s   t o   pr o v i de   I D S   a t t a c s i g na t u r e s .   E a c h   no de   i t h e   ne t w o r i s   r e s po ns i bl e   t o   p r o v i de   ne w   a t t a c s i g na t ur e   t o   be   s ha r e d   w i t o t h e r   no de .   T he r e   a r e   t w o   pr o bl e m s   e xi s t   i C I D S   hi g hl i g ht e i n   t hi s   p a pe r ,   f i r s t   i s   t o   pr o v i de   da t a   c o ns i s t e nc y   a nd  s e c o nd  i s   t o   m a i nt a i t r u s t   a m o ng   t he   no de s   w h i l e   s h a r i ng   t h e   a t t a c s i g na t ur e s .   R e c e n t l y ,   r e s e a r c he r   f i nd  t ha t   bl o c kc ha i ha s   a   g r e a t   po t e n t i a l   t o   s o l v e   t ho s e   p r o bl e m s .   C o ns e ns u s   a l g o r i t hm   i b l o c kc ha i i s   a bl e   t o   i nc r e a s e   t r us t s   a m o ng   t he   no de   a nd  a l l o w s   da t a   t o   be   i n s e r t e f r o m   a   s i ng l e   s o ur c e   o f   t r ut h.   I t h i s   p a pe r ,   w e   a r e   i nv e s t i g a t i ng   t h r e e   bl o c kc ha i c o ns e n s us   a l g o r i t hm s :   pr o o f   of   w or ( P o W ) ,   pr o o f   o f   s t a ke   ( P o S ) ,   a nd   hy br i P o W - P o S   c ha i n - ba s e d   c o ns e ns u s   a l g o r i t hm   w hi c a r e   po s s i bl y   t o   be   i m pl e m e n t e d   i C I D S .   F i na l l y ,   w e   de s i g a n   e xt e ns i o o f   h y br i P o W - P o S   c ha i n - ba s e c o ns e n s us   a l g o r i t hm   t o   f ul f i l l   t h e   r e qu i r e m e n t .   T h i s   e xt e ns i o w e   n a m e   i t   a s   pr o o f   o f   a t t a c s i g na t u r e   ( P o A S ) .     Ke y w or ds :   B l oc kc h a i n   CID S   Co n s e n s us   a l go r i t h m   ID S   S i g n a t u r e - b a s e d   T hi s   i s   an   ope n   ac c e s s   ar t i c l e   u nde r   t he   C C   B Y - SA   l i c e ns e .     Cor r e s pon di n g   Au t h or :   M o h Y a z i d   Id ri s ,     S c h o o l   of   Co m put i n g ,   F a c ul t y   of   E n gi n e e r i n g   U n i v e r s i t i   T e kn o l o gi   M a l a y s i a   E m a i l :   y a z i d@ u t m . m y   D e r i s   S t i a w a n   S c h o o l   of   Co m put i n g ,   F a c ul t y   of   E n gi n e e r i n g   U n i v e r s i t i   T e kn o l o gi   M a l a y s i a   E m a i l :   de ri s @ u n s ri . a c . i d         1.   I N TR O D U C TI O N   Co l l a b o r a t i v e   i nt r us i o de t e c t i o s y s t e m   (CID S ha s   b e e de s i g n e t o   e nha n c e   t h e   de t e c t i o n   c a pa b i l i t y   of   ID S .   CID S   a l l o w s   ID S   n o de s   t o   c o l l e c t   a n e xc ha n ge   r e qui r e d   i n f o r m a t i o n   a m o n t h e   n o de s   [1].   Co l l e c t i n t r a f f i c   c h a ra c t e r i s t i c s   a n a t t a c s i g n a t u r e s   f r o m   di f fe r e n t   n o de s   c r e a t e   m o r e   s e n s i t i v e   de t e c t i o n   c a pa b i l i t y   c o m pa r e t o   a   s i n g l e   n o de   ID S .   CID S   f r a m e w o r i s   w i de l y   a do pt e a n de pl oy e i n   v a r i o us   o r ga ni z a t i o n s   due   t o   i t s   de t e c t i o n   c a pa b i l i t y .   H ow e ve r ,   t h e r e   a r e   t w o   m a j o r   i s s ue s   r e m a i n   i n   CID S   w h i c h   a r e   c o n s i s t e n c y   o n   d a t a   s ha r i n a n d   t r us t   a m o n t h e   n o de s   [2 - 3] .   M a i n t a i ni n g   da t a   c o n s i s t e n c y   i s   a   b i c h a l l e n ge   i n   CID S   [4].   N o de s   a r e   r e qui r e t o   i de n t i fy   i n   w h i c h   pe e r   t o   c o l l e c t   t h e   l a t e s t   upd a t e   o f   a t t a c s i g n a t u r e s .   I n   s o m e   c a s e s ,   s e v e r a l   n o de s   pr o v i de   di ffe r e nt   v e r s i o n   o a t t a c s i g na t u r e s   t ha t   c a n   l e a t h e   d a t a   i n c o n s i s t e n c y   i s s ue .   T hi s   p r o b l e m   o c c ur s   due   t o   l a c o f   da t a   v e r s i o n i n g   c o n t r o l   s uc a s   i a   c e n t ra l i z e d   ID S   s y s t e m .   T h e   s e c o n i s s ue   i n   CID S   i s   t o   m a n a ge   t r us t   a m o n g   t h e   n o de s   [5].   T r us t   m a n a ge m e nt   i s   i m po rt a nt   t o   pr e v e n t   f a l s e   o m a l i c i o us   da t a   t o   b e   us e i CID S .   R e s e a r c h   i n   t r us t   m a n a ge m e nt   ha s   b e e n   di s c us s e i n   [6 - 9].   I n   o r de r   t o   m a i nt a i n   t h e   t r us t ,   a l l   t h e   da t a   c o n t r i b ut e s   by   e a c h   n o de   s h a l l   b e   v a l i da t e by   t h e   o t h e r   n o de s .   A l l   t h e s e   n o de s   c a n   c o n t r i b ut e   da t a   i n   a   n e t w o r w h e r e   e a c h   n o de   i s   c o n s i de r e b e n i g n .   I n   a c t ua l   c a s e   e a c h   n o de   i s   e xpo s e t o   m a l i c i o us   a c t i v i t i e s   s uc h   a s   i n s i de r   a t t a c k s .   T hi s   a t t a c c a n   c a us e   CID S   ge t t i n a n   i n v a l i da t a   a n d   g r e a t l y   de gr a de   t h e   s e c uri t y .     Evaluation Warning : The document was created with Spire.PDF for Python.
                                IS S N :   2502 - 4752   In do n e s i a J   E l e c   E ng  &   Co m S c i ,   V o l .   22 ,   N o .   1 A p r i l   20 21   :     4 8 5   -   4 9 6   486   T h e   s a m e   i s s ue s   o f   m a i nt a i n i ng  da t a   c o n s i s t e n c y   a n m a n a g i n t r us t   ha v e   be e n   di s c us s e i n   b l oc kc h a i t e c hn o l o gy   [9 - 10]  due   t o   i t s   na t u r e   t o   p r e v e n t   c r y pt o c urr e n c y   t ra n s a c t i o n   f r o m   b e i n m a ni pu l a t e i n   di s t r i b ut e n e t w o r k.   I CID S ,   r e s e a r c h e r s   a r e   do i n g   r e s e a r c h   t o   i de nt i fy   h o w   b l o c k c h a i c a n   i m p r o v e   s e c ur i t y   i n   CID S .   O n e   o f   t h e   f e a t ur e s   e xi s t s   i n   b l o c kc h a i de a l i ng  w i t h   t r a n s a c t i o n   d a t a   c o n s i s t e n c y   a nd  t rus t   i s   a   b l oc kc h a i n   c o n s e n s us   m e c ha ni s m .   T h i s   c o n s e n s us   m e c h a n i s m   a l l o w s   pe e r s   t o   v a l i da t e   t r a n s a c t i o t hr o ugh   i t s   c o n s e n s us   p r o o f i n a l go r i t h m   [ 11 - 13] .   T h e   a l go ri t h m   r e qu i r e s   n o de s   t o   c o m p e t e   t o   be   e l e c t e a s   a   t r us t e n o de   fo r   upda t i ng  t ra n s a c t i o n   i n   b l o c kc h a i n.   F u r t h e rm o r e   t hi s   a l go r i t hm   c a n   p r o v i de   da t a   c o n s i s t e n c y   by   h a v i ng  a   s i ngl e   s o u r c e   of   da t a   u pda t e   a t   o n e   t i m e .     M o ti v ati o n s :   T h e   pr o m i s i ng  s o l ut i o n   o c o n s e n s us   m e c ha n i s m   ha s   m o t i v a t e   us   t o   e xt e n t   t h e   b l oc kc h a i c o n s e n s us   a l go r i t hm   f o r   CID S .   R e c e n t   r e l a t e r e s e a r c h   c a b e   fo un i n   [ 14 - 18] .   I n   [1 4 - 15]   a ut h o r s   h a di s c us s e d   t h e   i m po rt a nt   o f   b l oc kc h a i n   i n   CID S .   O n   [1 6]  a ut h o r s   i nt r o duc e a   f r a m e w o r t ut i l i z e   b l o c kc h a i t o   i m p r o v e   t h e   pe r f o r m a n c e   o f   a n o m a l y   de t e c t i o n   v i a   c o n s e n s u s   m e c ha n i s m .   M e a n w h i l e   i n   [17 - 18]  a ut h o r s   h a de s i g n e a   c o l l a b o r a t i v e   b l o c k c h a i n   s i g n a t u r e - b a s e ID S   f r a m e w o r k,   w h i c h   c a i n c r e m e n t a l l y   e s t a b l i s h   a   t r us t e d   s i g na t u r e   da t a b a s e   i a   c o l l a bo r a t i v e   e n v i r o n m e nt   C o n tr i b u ti o n s :   M o t i v a t e by   t h e   r e c e n t   a c h i e v e m e n t   o f   b l o c k c h a i n   a n d   CID S   r e s e a r c h.   W e   h a v e   ra i s e a   c o n c e r n   t o   de s i gn   a n   e xt e n s i o n   of   c o n s e n s us   a l go ri t hm   i n   CID S .   T h e   e xt e n s i o n   m e a n s   t o   pr o v i de   t r us t e n o de s   a n d   a t t a c s i g na t u r e   c o n s i s t e n c y   t o   be   s t o r e i n   b l o c kc h a i n .   T h e   c o n t r i b ut i o n s   o o ur   w o r c a b e   s um m a r i z e d:     W e   i n v e s t i ga t e   t hr e e   b l o c k c h a i c o n s e n s us   a l go r i t hm s   a n d   de s i g n   a n   e xt e n s i o t o   v a l i d a t e   a t t a c s i g n a t u r e ,   m a i n t a i ni n d a t a   c o n s i s t e n c y   a n i n c r e a s e   t rus t   b e t w e e n   n o de s   b a s e o n   h y b r i P o W - P oS   Cha i n   b a s e c o n s e n s us   a l go r i t hm .   T h i s   e xt e n s i o n   p r o v i de s   CID S   s i g n a t u r e - b a s e r e l a t e de f i n i t i o n   o s t a ke s   a nd  t h e   m e a s u r e m e nt   o f   n o de ’s   c r e d i b i l i t y   t o   t a ke   c a r e   o f   n e t w o r f r o m   m a l i c i o us   a c t i v i t i e s .     T h i s   p a pe r   i s   o r ga ni z e i n   s e c t i o n s S e c t i o n   a r e   b a c kgr o u n a n r e l a t e w o r CID S   a n d   b l oc kc h a i n   r e s e a r c h.   I n   s e c t i o n   3,   w e   i nt r o duc e   t h e   b l oc kc h a i n   c o n s e n s us   a l go ri t hm S e c t i o n   i s   de s i gni n g   pr o o f   of   a t t a c s i g na t u r e   (P o A S c o n s e n s us   a l go r i t hm   a nd  de s c r i b e   e l e m e n t   a nd  p r o c e s s   of   P o A S .   F o r   s e c t i o n   i s   o ur  i ni t i a l   e xpe ri m e nt   a n d   r e s ul t   s e c t i o n   6   w e   c o n c l ude   our  f i n di ngs   a nd  s ug ge s t   f o r   f ut u r e   w o r ks       2.   B A C K G R O U N D   A N D   R ELA TED   W O R K   Co l l a b o r a t i v e   i n t r us i o n   d e t e c t i o n   s y s t e m s   ( CID S )   a r e   de pl o y e d   i n   n e t w o r b a s e o n   t hr e e   t y pe s   o a r c hi t e c t u r a l   de s i g i n c l ud i n c e n t ra l i z e d   CID S ,   d e c e n t ra l i z e CID S   a n d i s t ri b ut e CID S   s uc a s   i n   F i g u r e   1.   Ce n t ra l i z e CID S   i s   de pe n d i n o n   a   s i n gl e   c o n t r o l   po i n t   a n r e qu i r e   l e s s   e ffo r t   t o   de pl oy   [19].   M e a n w h i l e   t h e   de c e n t ra l i z e CID S   di s pe r s e   a   s i ngl e   c o n t r o l   po i n t   t o   m ul t i p l e   i n t e r c o nn e c t e c o n t r o l   po i nt   [20 - 21]  t a v o i de pe n de n c i e s   o n   s i n gl e   s e r v e r.   T h e   t h i r c a t e go r y   of   CID S   i s   di s t ri b ut e CID S   w i t h   n o   c o n t r o l   po i n t   de pl oy e d.   T h e   de t e c t i o n   t a s ks   a r e   di s t ri b ut e d   a m o n n o de s   t o   r e que s t   or   r e c e i v e   da t a   f r o m   pe e r s   [22 - 23] D i s t r i b ut e d   CID S   ha s e v e r a l   i de nt i f i e i s s ue s   i n c l udi ng  t h e   da t a   c o n s i s t e n c y   a n t r us t   a m o n t h e   pe e r s .   D a t a   a r e   m o v i n f r o m   o n e   n o de   t o   a n o t h e r   n o de   w i t h   pe e r   t o   pe e r   (P 2P c o m m u n i c a t i o n.   I n   d i s t ri b ut e CID S ,   e a c n o de   c a n   h o l d   di f f e r e n t   s e t   o f   da t a .   T h e   d a t a   d i s t r i b ut e   a c r o s s   t h e   n e t w o r w i t w i t h o ut   a   p r o pe r   c o n t r o l .             F i gu r e   1 .   O v e r v i e w   of   c e n t ra l i z e d,   de c e n t ra l i z e a n d   di s t r i b u t e CID S   a r c h i t e c t ur e s       D i s t r i b ut e d   CID S   i m p r o v e s   pe r fo r m a n c e   a nd  e l i m i na t e   a   s i n g l e / m u l t i pl e   po i n t   o f   f a i l u r e s   i n   CID S .   R e ga r di n t h e   m i t i g a t i o n   o da t a   c o n s i s t e n c y   a n t r us t   i s s ue s   w i t h i n   d i s t ri b ut e CID S ,   v a r i o us   m e t h o ds   of  t r us t   m a na ge m e nt   ha v e   be e n   de v e l o pe a m o n g   CID S   n o de s .   In  [9]   s ugge s t e t ha t   t h e   ID S   n o d e s   c o n t i nuo us l y   m o n i t o r   t h e   b e h a v i o r   of   t h e i r   CID S   pe e r s   a n e v a l ua t e   t h e   qu a l i t y   of  t h e   s e c ur i t y - r e l a t e i n f o r m a t i o n   t h a t   t h e y   Evaluation Warning : The document was created with Spire.PDF for Python.
In do n e s i a J   E l e c   E ng  &   Co m S c i     IS S N :   2502 - 4752       D e s i gni ng  c ons e ns us   a l gor i t hm   f or   c ol l abor a t i v e   s i gn a t ur e - b as e i nt r us i on …  ( E k A r i p   W i nant o )   487   s h a r e   t o   e s t i m a t e   t h e i r   c r e di b i l i t y .   A n y   da t a   c o nt r i b ut e d   by   a   CID S   n o de   i s   t a ke i nt o   c o n s i de ra t i o n   de pe n di n g   o t h e   n o de s   c a l c ul a t e c r e d i b i l i t y .   A pa r t   f r o m   m e a s u r i ng  t h e   c r e di b i l i t y   o CID S   n o de s ,   c a l c ul a t i n a nd  m a i n t a i ni n t h e   t r us t w o r t h i n e s s   o e xt e r na l   IP   s o ur c e s   ha v e   a l s o   b e e n   p r o po s e [3].   By   f i l t e r i ng  t h e i r   i n c o m i n pa c ke t s   a c c o r di n t o   a   c o l l a b o r a t i v e   t r us t - b a s e s c h e m e ,   l a r ge - s c a l e   D D o S   a t t a c ks   c a n   b e   m i t i g a t e d.   T h e   pa c ke t   f i l t e r i ng  m e c h a ni s m   i s   r e l i e o n   b l a c kl i s t e (i . e .   u nt r us t e d)  IP   s o ur c e s   t a b l e   w h o s e   pa c ke t s   a r e   i m m e di a t e l y   dr o ppe d,   w i t h o ut   f ur t h e r   i n s pe c t i o n   a nd  a na l y s i s ,   t h us   re duc i n t h e   w o r kl o a o f   de t e c t i o n   uni t s .   T h e   c h a l l e n ge   i n   t h e   c a s e   of   di s t r i b ut e CID S   i s   t h a t   t h e r e   i s   n o   c e n t r a l   t r us t e a u t h o r i t y   t o   s upp o r t   t h e   e s t a b l i s hm e nt   o f   c oo r di n a t i o n   b e t w e e n   t h e   pe e r s   [13 ].   I n   t h e   s e que l ,   w e   a ddr e s s   t hi s   c ha l l e n ge   by   pr o po s i n a   b l oc kc h a i s o l ut i o n ,   t o   s e c ur e   t h e   c r e d i b i l i t y   of   t h e   CID S   da t a .   B l oc kc h a i n   i nt r us i o n   d e t e c t i o n   s y s t e m :   B l o c k c h a i n   w a s   d e s i gn e t o   pr o t e c t   a   pub l i c   di s t r i b ut e l e dge r   o f   c r y pt oc urr e n c y   i n   a   t r us t l e s s   P 2P   n e t w o r [24] .   T hi s   di s t ri b ut e l e dge r   l o c a t e i n   a   s e r i e s   o f   b l oc ks   a n n e e ds   t o   b e   s e c ur e by   d e pl oy i n a   ha s h i ng   m e c h a ni s m   t o   p r o v i de   a n   i m m u t a b l e   l e dge t ra n s a c t i o n   hi s t o r y .   M o r e ove r ,   a   b l o c k c h a i n   t hr o ug h   i t s   c o n s e n s us   m e c ha n i s m   a l l o w s   pu b l i c   n o de s   i n   di s t r i b ut e n e t w o r t o   v a l i da t e   t r a n s a c t i o n A l l   n o de s   h a v e   a   r i g ht   t o   c o m pe t e   t pus h   t h e   t r a n s a c t i o n   da t a   t o   a   b l oc kc h a i n   b l o c k.   T h i s   p r o c e s s   r e qui r e s   b l o c k c h a i n e t w o r i m pl e m e n t i n a   c o n s e n s us   s t r a t e g y .   T h i s   s t ra t e g y   i s   t o   a v o i t h e   s a m e   t ra n s a c t i o n   upd a t e by   m a n y   n o de s   (a vo i di n da t a   i n c on s i s t e n c y ),   a nd  e n s u ri n da t a   i s   v a l i a n up da t e   by   a   t r us t e n o de   t hr o u g c o n s e n s us .     S i n c e   t h e   e a r l y   s t a ge   o f   di s t ri b ut e CID S   r e s e a r c h ,   da t a   c on s i s t e n c y   a n d   t r us t   i s s ue s   i n   d i s t ri b ut e d   c o l l a bo r a t i v e   n e t w o r ge t   a   l o t   o f   i n t e nt i o n s .   W h e n   b l o c kc h a i n   t e c hn o l o g y   h a s   b e e n   e m e r ge d,   t h e   s o l ut i o n   t o   f i l l   t h e   r e qu i r e d   s e c ur i t y   ga i n   d i s t ri b ut e CID S   i s   q ui t e   p r o m i s i n g T h e   f i r s t   p r o po s e CID S   s y s t e m   w i t b l oc kc h a i n   t e c hn o l o g y   c a n   b e   fo un i n   [ 14] ,   a u t h o r s   de s c r i b e a   f r a m e w o r t o   de m o n s t r a t e   h o w   b l o c kc h a i n   c a n   b e   i m pl e m e n t e i CID S .   T h e   a ut h o r   s t a t e s   i nt e r s e c t i o n   o f   CID S s   a n d   b l o c k c h a i n s .   P a r t i c ul a rl y ,   i t   i n t r o duc e s   t h e   i de a   o f   ut i l i z i n g   b l o c kc h a i n   t e c hn o l o gi e s   a s   a   m e c h a ni s m   f o r   i m p r o v i n CID S .   T h e y   a r gue   t h a t   c e r t a i n   p r o pe rt i e s   o f   b l o c kc h a i n s   c a b e   of   s i gn i f i c a nt   b e n e f i t   f o r   CID S ;   n a m e l y   f o r   t h e   i m p r o v e m e n t   o f   t r us t   b e t w e e n   m o ni t o r s ,   a nd  f o r   p r o v i di n a c c o un t a b i l i t y   a n c o n s e n s us .   T h e y   s h o w   t h e   r e l a t e w o r a n hi g h l i g ht   t h e   r e s e a r c h   g a ps   a nd  c ha l l e n ge s   t o w a r ds   s uc h   a   t a s k .   F i na l l y ,   t h e   a ut h o r   p r o po s e s   a   ge n e r i c   a r c h i t e c t u r e   f o r   t h e   i n c o r po ra t i o n   o f   b l o c kc h a i n s   i nt o   t h e   f i e l o f   C ID S .   O o t h e h a nd  [15 a u t h o a l s o   pr o v i de t h e   r e v i e w   r e ga rdi n t h e   i nt e r s e c t i o n   o f   b l oc kc h a i n   a nd  i n t rus i o n   de t e c t i o n,   i n t r o duc e   t h e   po t e n t i a l   a pp l i c a t i o n   o f   s u c h   c o m b i na t i o n .   T h e y   i n d i c a t e t ha t   b l o c kc h a i n   c a h e l e nha n c e   ID S   i n   t h e   a s pe c t s   o f   da t a   s h a ri n g ,   t r us t   c o m put a t i o n   a n d   a l a rm   e xc h a nge .     In   a n o m a l y   d e t e c t i o n ,   [16]  de s c r i b e a   f r a m e w o r t ha t   u t i l i z e s   t h e   b l o c kc h a i n   c o n c e pt   t o   pe r f o r m   di s t r i b ut e a nd   c o l l a b o r a t i v e   a n o m a l y   de t e c t i o n   fo r   de v i c e s   w i t h   l i m i t e r e s o ur c e s .   T h e   f ra m e w o r us e s   b l oc kc h a i n   t o   i n c r e m e n t a l l y   a   t r us t e a n o m a l y   d e t e c t i o n   m o de l   v i a   s e l f - a t t e s t a t i o n   a n c o n s e n s us   a m o n Io T   de v i c e s .   In   t hi s   c a s e ,   e a c h   de v i c e   w i l l   c r e a t e   i t s   o w n   i n t e l l i ge n c e   m o de l   unde r   n o r m a l   n e t w o r c o n di t i o n s   a nd  pe r i o di c a l l y   e ve r y   t   t i m e   e l a ps e s ,   a n   a ge n t   u pda t e s   i t s   r e po rt   i n   t h e   l o c a l l y   s t o r e c h a i n ’s   p a r t i a l   b l o c k.   T h e   a ge nt   t h e b r o a dc a s t s   t h e   e nt i r e   l o c a l l y   s t o r e c h a i t o   a l l   n e i g h b o ur i n g   a ge n t s .   T h e   l i m i t a t i o n   i s   t ha t   n o b o d y   v e r i f i e s   t h e   i n t e l l i ge n c e   m o de l   c r e a t e by   t h e   ID S   n o de   be c a us e   t h e   i n t e l l i ge n c e   m o de l   i s   b a s e o n   n o rm a l   t r a f f i c   i t h e   l o c a l   n e t w o r k.     By   c o n t ra s t ,   [17 - 18]  de m o n s t r a t e h o w   t us e   b l o c k c h a i n s   t o   e nh a n c e   t h e   pe r f o r m a n c e   of  c o l l a bo r a t i v e   s i gna t u r e - b a s e ID S   v i a   b ui l di n g   a   v e r i f i a b l e   a t t a c s i g na t u r e s .   T h e y   de s i gn   t hi s   f r a m e w o r t o   c o n s o r t i u m   b l oc kc h a i n.   E a c h   ID S   n o de   i n   t h e   c o n s o r t i um   b l o c kc h a i n   c a n   m o n i t o r   t h e   n e t w o r t r a f f i c ,   i de n t i f y   a t t a c ks ,   a nd  pe r i o di c a l l y   s h a r e   a   s e t   o f   a t t a c s i g n a t u r e s   w i t h   o t h e r s .   T hi s   s e t   o f   a t t a c s i g n a t u r e s   ha s   t o   be   s i g n e by   a   pr i v a t e   ke y   a n a   p ub l i c   ke y ,   i n   o r de r   t o   un de r s t a n t h e   s o ur c e   of   a t t a c s i g n a t u r e s .   O t h e r   n o de s   w i l l   o n l y   a c c e pt   t h e s e   a t t a c s i g na t u r e s   by   ve r i fy i n t h e m   a ga i n s t   t h e i l o c a l   d a t a b a s e .   I t hi s   c a s e ,   t h e   b l oc kc h a i n   c a n   b e   o n l y   e xpa n de i f   t h e   m a j o ri t y   of   n o de s   ha v e   v e r i f i e t ha t   t h e   r e c e i v e b l oc c o n t a i n s   t r us t e r u l e s .   T h e   l i m i t a t i o n   i s   n o t   a l l   n o de s   c a n   p r o v i de   a n   a t t a c s i g na t u r e   b e c a us e   i t   us e s   t h e   c o n c e pt   o f   a   c o n s o r t i u m   b l o c kc h a i n.       3.   B L O C K C H A I N   C O N S EN S U S   A L G O R I T H M   B l oc kc h a i n   c o n s e n s us   a l go r i t hm   i s   a   c r uc i a l   pa rt   i b l o c kc h a i n   t e c hn o l o g y .   T h i s   a l go r i t h m   m a i nt a i n s   t h e   da t a   v a l i di t y   w h i c h   r e c o r de o n   t h e   c h a i n i n g   b l o c k.   T h e   c o n s e n s us   a l go ri t hm   r e qui r e s   a   t e c hni que   t o   e n s u r e   t h e   pub l i c   n o de s   a r e   t r us t e a nd  r e s po n s i b l e   fo r   da t a   upda t e s .   T hi s   a l go r i t h m   f o l l o w s   t h e   c o n c e pt   of  ga m e   t h e o r y .   It   i s   a   s t ra t e gy   fo r   de a l i n w i t h   c o m pe t i t i v e   s i t ua t i o n s   w h i c h   i s   de pe n di ng  o n   t h e   a c t i o n s   of  pa r t i c i pa t e n o de s .   N o de s   i n   t h e   n e t w o r w i l l   c o m pe t e   t o   s pe n t h e i r   r e s o ur c e s   o r   t o   h a v e   a   l a r ge   o s t a ke s   t i n c r e a s e   c ha n c e s   fo r   upda t i n d a t a   i n   a   b l o c k c h a i n .   I n   t h e   f i rs t   s t ra t e gy   of   s pe n di n r e s o ur c e s ,   i t   c a n   b e   fo un i n   p r o of   of   w o r (P o W c o n s e n s us   a l go r i t hm ,   m e a n w h i l e   t he   s e c o n s t ra t e gy   h a s   b e e n   i m p l e m e nt e i n   p r o of  of   s t a ke   (P o S a l go r i t hm .     Evaluation Warning : The document was created with Spire.PDF for Python.
                                IS S N :   2502 - 4752   In do n e s i a J   E l e c   E ng  &   Co m S c i ,   V o l .   22 ,   N o .   1 A p r i l   20 21   :     4 8 5   -   4 9 6   488   P r oo o w o r k   (P o W) :   In   P o W   t h e   n o de s   i n   t h e   b l oc kc h a i n   n e t w o r r e a c h   c o n s e n s us   b y   pa r t i c i pa t i n g   i n   ha s h i ng  puz z l e   s e a r c h i n p r o c e s s ,   w h e r e   e a c h   n o de   m us t   f i n a   n o n c e   v a l ue   t o   ge n e r a t e   a   n e w   b l oc k.   T h e   n o n c e   i s   a   v a l ue   i n   a   ha s h   f un c t i o n   t o   be   i de n t i f i e t o   m a ke   t h e   c urr e n t   h a s h   d a t a   i s   pa rt i a l l y   i de nt i c a l .   T h e   i n pu t   o f   h a s h   f u n c t i o n   i s   a   p r e v i o us   h a s h   da t a ,   a n t o   ge t   t h e   t a r ge t   n o n c e   a   hi g h   c o m put a t i o n a l   pow e r   i s   r e qui r e u n t i l   t h e   t a r ge t   v a l ue   o f   a dj us t e c urr e nt   ha s d a t a   i s   a c h i e v e d.   T h e   f i r s t   n o de   t ha t   b e   a b l e   t o   s o l ve   t h e   pu z z l e   w i l l   b e   a u t h o r i s e t o   c r e a t e   a n d   i n s e r t   d a t a   i t h e   b l o c k,   a nd  b r o a dc a s t   t h e   b l o c a l o n w i t h   t h e   d a t a   t o   o t h e r   n o de s .   In  P o W ,   t h e   hi g h e c o m put a t i o na l   po w e r   n o de   m i g ht   ha v e   h i g h e r   c h a n c e s   t o   be   t h e   w i nn e a n d   e n t i t l e   t o   r e c e i ve   t h e   r e w a r d   [25] .     P r oo o s tak e   (P o S ) :   P o S   w a s   de ve l o pe d   a s   a   c o n s e n s us   m e c h a ni s m   w i t h   t h e   a i m   t o   r e duc e   t h e   c o m put a t i o n a l   r e qu i r e m e nt s   o f   P oW .   I n   c r y pt oc urr e n c y   b l oc kc h a i n,   pa rt i c i p a n t s   w i t h   hi g h e r   c o i a ge   o f   t h e   c o i n   i n - n e t w o r k   a n t h e i r   h o l di ng  t i m e   h a v e   hi g h e r   c ha n c e s   t o   be   s e l e c t e d.   T h e   di f f i c ul t y   l e ve l   of   h a s h i n g   puz z l e   P o W   c a n   b e   r e duc e by   c o n s um i n c o i n   a ge .   A   c o m pl e t e   P o S   n e t w o r k,   t h e   ha s h   s e a r c hi n pu z z l e   i s   c o m pl e t e l y   r e m ov e d,   a nd  t h e   b l o c l e a de r s   a r e   n o   l o n ge r   s e l e c t e by   c o m put a t i o n a l   po w e r .   H ow e ve r   due   t t h e   s e c ur i t y   i s s ue   r e s e a r c h e r   hi g h l i g ht e a   c o m b i na t i o n   o f   P oW   a n d   P o S   i s   b e t t e t o   a v o i s t a ke   m a ni pul a t i o n.     T h e r e   a r e   s e ve r a l   P o S   a l go r i t hm s   i n c l udi ng  c ha i n - b a s e P o S   [26],   c o m m i t t e e - b a s e P oS   [27],   by z a n t i n e   f a ul t   t o l e ra n c e   (B F T ) - b a s e P o S   [28] - [29]  a n d   d e l e ga t e P o S   (D P o S [30].   A m o n g   t h e s e   f o ur   t y pe s   of   P o S ,   t h e   C h a i n - b a s e i s   r e l i e s   o n   s t a ke s   a nd  c o m put a t i o na l   w o r ks   t o   s e l e c t   a   t r us t e n o de   [26].   M e a n w hi l e   c o m m i t t e e - b a s e P o S   c o m m i t t e e - b a s e P o S   d e t e r m i ni n a   c o m m i t t e e   of  s t a ke h o l de r s   b a s e o n   t h e i r   s t a ke s   a n a l l o w i n t h e   c o m m i t t e e   t o   ge n e r a t e   b l o c ks ,   t h e   B F T - b a s e P o S   i s   a   P o S   c r e a t e d   o n   t o o f   B F T   a l go r i t h m .   O t h e   o t h e ha n d ,   D P o S   i s   c l a s s i f i e a s   a   de m o c r a t i c   s e l e c t i o n   f o r m   o f   t rus t e n o de   v i a   pub l i c   s t a ke   de l e ga t i o n.   A m o n t h e s e   f o ur   a l go ri t hm s ,   C ha i n - b a s e P o S   h a i m pl e m e nt e a   h y b r i P o W   a n P o S   s t ra t e gy .   In   t h i s   p a pe r,   w e   e xt e n t   t h e   C ha i n - b a s e P o S   t de ve l o a   c o n s e n s us   a l go ri t hm   t ha t   h a s   b e t t e s e c ur i t y   s uc h   a s   i P o W   b ut   r e duc e   c o m put a t i o n a l   r e s o ur c e s .     C h ai n - b as e d   P o S :   Ch a i n - b a s e P oS   i s   a n   e nh a n c e b l o c k   ge n e ra t i o n   m e c ha n i s m   w i t h   P o W   a n P o S   c h a ra c t e ri s t i c .   C h a i n - b a s e P o S   i nh e r i t s   m a n y   of   t h e   c om po n e n t s   o f   t h e   P o W   c o n s e n s us   p r o t o c o l   s uc h   a s   i n f o r m a t i o p r o pa ga t i o n ,   b l o c v a l i d a t i o n ,   a n d   b l o c f i n a l i z a t i o (i . e .   l o n ge s t - c h a i r u l e ),   e xc e pt   t ha t   t h e   b l oc ge n e r a t i o n   m e c ha ni s m   i s   r e pl a c e w i t h   P o S .   P o S   doe s   n o t   hi n ge   o n   w a s t e f ul   h a s h i ng  t o   ge n e r a t e   b l oc ks   l i ke   P o W .   A   m i n t e r   c a s o l v e   t h e   h a s hi n puz z l e   o nl y   on c e   f o r   a   c l o c t i c k.   S i n c e   t h e   ha s h i n g   pu z z l e   di f f i c ul t y   de c r e a s e s   w i t h   t h e   m i nt e r ’s   s t a ke   v a l ue ,   t h e   e xpe c t e n um b e r   o f   h a s h i ng  a t t e m p t s   f o r   a   m i nt e r   t o   s o l ve   t h e   puz z l e   c a n   b e   s i gni f i c a nt l y   r e duc e i f   h e   s t a ke   v a l ue   i s   h i g h.   T h e r e f o r e ,   P o S   a vo i ds   t h e   b r ut e - f o r c e   ha s h i n g   c o m pe t i t i o n   t ha t   w o ul o c c ur   ha P o W   b e e n   us e d,   t h us   a c h i e v i n a   s i g ni f i c a n t   r e duc t i o i n   e n e r gy   us a ge .   T h e   e xt e n s i o C ha i n - b a s e P o S   i s   f ut u r e   di s c us s e i S e c t i o n   4.       4.   D ES I G N I N G   P R O O F   O F   A TTA C K   S I G N A TU R E   (P o A S )   P o A S   i s   a n   e xt e n s i o n   o f   Ch a i n - b a s e P o S .   P o S   w a s   i n v e n t e t o   r e duc e   c o m put a t i o n a l   po w e r   r e qui r e i n   P o W   fo r   m i n i ng  pu r po s e s .   I n   P o S   t h e   s e l e c t i o n   of   n o de s   i s   de f i n e by   i t s   pr o po r t i o n   o w n e r s h i p   v a l ue ,   a n t h us   t h e   h i g h e s t   s t a ke   o w n e r   w i l l   a l w a y s   ge t   a   c h a n c e   t o   v a l i da t e   t h e   t r a n s a c t i o n.   I t   h a s   b e e n   a r gue i [31 ],   e v e n   P o S   s o l ve s   i s s ue s   i n   P o W   s uc h   a s   hi g h   c o m put a t i o n a l   r e s o ur c e s   b ut   P o S   r a i s e   a   c o n c e rn  o n   t h e   w a y   of   i t s   de t e r m i n a t i o n   o s t a ke s   ow n e r s hi w h e r e   i t   c a n   b e   d o m i n a t e by   a   s a m e   gr o up  o n o de s .   T h e n,   a   h y b r i P o S   a nd  P o W   w a s   i nt r o duc e t o   i n c r e a s e   c re di b i l i t y   o n   s e l e c t i n g   o n   b o t h   c ri t e r i a s   b a s e o n   c o m put a t i o n a l   po w e r   a nd  s t a ke   s uc h   a s   i n   C h a i n - b a s e P o S .       4. 1 .       C h a i n - b as e d   P o S   T h e   ge n e r a l   p r o c e dur e   of   Ch a i n - b a s e P o S   i s   s um m a r i z e i n   F i g u r e   [26].   I n   C ha i n - b a s e P o S   t h e   de t e r m i n a t i o n   o s t a ke   b a s e d   o n   t h e   ow n e r s hi c r y pt o c ur r e nc y   v a l ue   a n i t ’s   a ge .   T h e   h i g h e r   v a l ue   o s t a ke   i n di c a t e s   a   hi g h   l oy a l t y   of   n o de s   i n   t h e   n e t w o r k.   C h a i n - b a s e P o S   i n c l ude   t h e   fe a t u r e s   of   P oW   t o   s o l v e   a   ha s h i n g   pu z z l e   o n   i t s   f un c t i o n.   H ow e ve r   t h e   d i f f i c ul t y   of   h a s h i ng  pu z z l e   de t e rm i n e   b y   t h e   s t a ke .   T h e   c o m b i na t i o n   b e t w e e n   s t a ke   a n ha s h i ng  pu z z l e   l o c a t e   i n   b l oc kge n   f un c t i o n .   A   n o n c e   (C)  i n   B l o c kG e n   f un c t i o n   i s   a n   i nput   v a l ue   t o   fo r m   t h e   t a r ge t   ha s h   o ut put .   T he   f i r s t   s uc c e s s f ul   n o de   w i l l   be   a b l e   t o   c r e a t e   a nd  i n s e r t   d a t a   t o   a   n e w   b l o c k.   T h i s   p r o c e s s   i s   r e pe a t e o n c e   a   n e w   t ra n s a c t i o n   i s   a rr i v e d.       4. 2 .       D e s i gn i n g   P o A S   e x te n s i o n   o n   c h ai n - b as e d   P o S   In   F i gu r e   i s   p r o po s e P o A S   a r c hi t e c t u r e .   P o A S   i s   de s i g ne w i t h   a   pub l i c   b l o c kc h a i n   t ha t   a l l o w s   w h o   t j o i n   t h e   n e t w o r k.   I n   s i m pl e   t e rm s ,   P o A S   e n s ur e s   t h a t   a t t a c s i gna t u r e s   pr o duc e by   n o d e s   a r e   r e l i a b l a n c o n s i s t e n t .   T h e   p r o c e s s   i s   e a c h   of   a t t a c s i g n a t u r e   v a l i d a t e by   a l l   n o de s   o n   t h e   n e t w o r b e fo r e   s t o r e   i n   t h e   b l o c kc h a i n.         Evaluation Warning : The document was created with Spire.PDF for Python.
In do n e s i a J   E l e c   E ng  &   Co m S c i     IS S N :   2502 - 4752       D e s i gni ng  c ons e ns us   a l gor i t hm   f or   c ol l abor a t i v e   s i gn a t ur e - b as e i nt r us i on …  ( E k A r i p   W i nant o )   489   F i gu r e   2 .   P s e udo c o de   Cha i n - b a s e P o S   [26]   P s e u d o c o d e   1 C h a i n - b a s e d   P o S     J o i n   t h e   n e t w o rk   b y   c o n n e c t i n g   t o   k n o w n   p e e r s ;       D e p o s i t   i n   t h e   s t a k e   p o o l ;       S t a rt   Bl o c k G e n ();       / *   M a i n   l o o p   * /     w h i l e   ru n n i n g   do         i B l o c k G e n ( )   r e t u rn s   b l o c k   t h e n   6     W ri t e   b l o c k   i n t o   b l o c k c h a i n ;   7   Re s e t   Bl o c k G e n ()  t o   t h e   c u rr e n t   b l o c k c h a i n ;         / *   G o s s i p i n g   r u l e   * /       Bro a d c a s t   b l o c k   t o   p e e r s ;   9     e n d         / *   L o n g e s t - c h a i n   * /   10     i b l o c k   r e c e i v e d   &   i s   v a l i d   &   e x t e n d s   t h e   l o n g e s t   c h a i n   th e n   11   W ri t e   b l o c k   i n t o   b l o c k c h a i n ;   12   Re s e t   B l o c k G e n ( )   t o   t h e   c u rr e n t   b l o c k c h a i n ;   13   Re l a y   b l o c k   t o   p e e r s ;   14     e n d   15    e n d     / *   P o S - b a s e d   b l o c k   g e n e r a t i o n   * /   16    F u n c t i o n   B l o c k G e n () :     17      P re p a r e   a   b l o c k   h e a d e r   a n d   b l o c k c h a i n   i n f o rm a t i o n       / *   P o S   h a s h i n g   p u z z l e   * /     18       S e t   u p   a   c l o c k   ( w h o s e   t i c k   i n t e r v a l   i s   a   c o n s t a n t a n d   c h e c k   fo t h e   fo l l o w i n g   c o n d i t i o n   p e c l o c k   t i c k :       H a s h   (C | c l o c k   t i m e <   t a r g e t × s t a k e   v a l u e   19      r e tu r n   n e w   b l o c k ;   20    e n d             F i gu r e   3 .   T h e   p r o c e s s   of   P r o of   of   A t t a c S i g na t u r e       P s e udoc o de   1   i s   e xt e n t   t o   f ul f i l l   t h e   r e qui r e m e nt   o Ch a i n - b a s e P oS   c o n s e n s us   a l go ri t hm   i n   CID S .   It   r e qui r e s   e xt e n s i o n s   i n   s e ve r a l   p a r t s   o t h e   a l go ri t hm   i nc l udi n s t a ke   v a l ue   de f i n i t i o n ,   a t t a c s i g n a t u r e   v a l i da t i o p r o c e s s ,   de t e r m i n i ng  n o de   r e put a t i o n   a n b l o c ge n e r a t i o n .   F i gu r e   4   s h o w s   P o A S   ps e ud o c o d e   e xt e n s i o n.           Evaluation Warning : The document was created with Spire.PDF for Python.
                                IS S N :   2502 - 4752   In do n e s i a J   E l e c   E ng  &   Co m S c i ,   V o l .   22 ,   N o .   1 A p r i l   20 21   :     4 8 5   -   4 9 6   490   F i g u r e   4 .   P o A S   P s e udo c o d e   P s e u d o c o d e   2 :   P o A S   C o n s e n s u s   A l g o ri t h m     J o i n   t h e   n e t w o rk   b y   c o n n e c t i n g   t o   k n o w n   p e e r s ;       Co n d u c t   a t t a c k   s i g n a t u re   v a l i d a t i o n   t o   g e t   i n i t i a l   r e p u t a t i o n ;   3   Re c e i v e d   a t t a c k _ s i g n a t u r e   4   W ri t e   r e p u t a t i o n ;     S t a rt   V a l i d a t e ( a t t a c k _ s i g n a t u r e );       / *   M a i n   l o o p   * /     w h i l e   ru n n i n g   d o   7     i V a l i d a t e ( r e t u r n s   c l a s s   a t t a c k   t h e n   8     Ca l c u l a t e   m a j o ri t y   o v a l i d a t i o n   p r o c e s s ;   9     i m a j o r i t y   r e a c h   m o r e   t h a n 5 0 %   o f   s t a k e   a n d   c o r r e c t   t h e n   10   A d d   i n i t i a l   r e p u t a t i o n   +   0 . 2   i n t o   re p u t a t i o n ;         11   S t a rt   Bl o c k G e n ( a t t a c k _ s i g n a t u r e );   12     e n d   13     e l s e   14     P ro s e s   e n d ;   15     e n d   16     e n d   17      i B l o c k G e n ( )   r e t u rn s   b l o c k   t h e n   18   W ri t e   b l o c k   i n t o   b l o c k c h a i n ;   19   A d d   r e p u t a t i o n   +   1   i n t o   re p u t a t i o n ;   20   Re s e t   Bl o c k G e n ()  t o   t h e   c u rr e n t   b l o c k c h a i n ;         / *   G o s s i p i n g   r u l e   * /   21      Bro a d c a s t   b l o c k   t o   p e e r s ;   22     e n d         / *   L o n g e s t - c h a i n   * /   23     i b l o c k   r e c e i v e d   &   i s   v a l i d   &   e x t e n d s   t h e   l o n g e s t   c h a i n   t h e n   24   W ri t e   b l o c k   i n t o   b l o c k c h a i n ;   25   Re s e t   B l o c k G e n ( )   t o   t h e   c u rr e n t   b l o c k c h a i n ;   26       Re l a y   b l o c k   t o   p e e r s ;   27     e n d   28    e n d     / *   P o S - b a s e d   b l o c k   g e n e r a t i o n   * /   29    F u n c t i o n   Bl o c k G e n ( a t t a c k _ s i g n a t u r e ):     30     P re p a r e   a   b l o c k   h e a d e r   a t t a c k   s i g n a t u r e   a n d   b l o c k c h a i n   i n fo r m a t i o n ;         / *   P o S   h a s h i n g   p u z z l e   * /     31    S e t   u p   a   c l o c k   ( w h o s e   t i c k   i n t e r v a l   i s   a   c o n s t a n t a n d   c h e c k   fo t h e   fo l l o w i n g   c o n d i t i o n   p e c l o c k   t i c k :         H a s h   (C | c l o c k   t i m e <   t a r g e t   ×   re p u t a t i o n ;   32      re t u r n   n e w   b l o c k ;   33    e n d     / *   V a l i d a t e   a t t a c k   s i g n a t u r e   * /   34   F u n c t i o n   V a l i d a t e ( a t t a c k _ s i g n a t u r e ):   35     Re a d   a t t a c k   s i g n a t u r e   r e p o s i t o ry   i n t o   S ;   36     W ri t e   a n d   c a l l   f u n c t i o n   S t ri n g t o N u m e ri c ()   t o   c o n v e rt   a t t a c k _ s i g n a t u r e ;   37     W ri t e   a n d   c a l l   f u n c t i o n   S t ri n g t o N u m e ri c ()   t o   c o n v e rt   S ;   38     Ca l c u l a t e   w i t h   K N N   a l g o ri t h m   ( m o r e   d e t a i l   i n   p s e u d o c o d e   3 );   39      re t u r n   c l a s s   a t t a c k ;   40    e n d     / *   Co n v e r t   a t t a c k   s i g n a t u r e   t o   n u m e r i c a l   * /   41   F u n c t i o n   S t ri n g t o N u m e ri c ( a t t a c k _ s i g n a t u r e ):   42     W ri t e   x   a rra y   t o   s t o r e   re s u l t   c o n v e rt   a t t a c k   s i g n a t u re ;   43     fo S i ,   Є   a t t a c k _ s i g n a t u r e   do   44       W ri t e   Z   45   i S i   n o t   n u m b e t h e n   46     Co n v e rt   S i   t o   A S CII  i n t o   Z;   47     S u m   Z;   48   A p p e n d   Z   i n t o   x ;       49   e n d     50     e l s e     51       A p p e n d   S i   i n t o   x ;   52     e n d   53     e n d   54      re t u r n   x ;   55    e n d       S tak e   v al u e   d e fi n i ti o n S t a ke   i n   c r y pt oc urr e n c y   b l oc kc h a i n   i s   de f i n e i n   a   f o r m   o f   c urr e n c i e s   v a l ue ,   w h i c r e f l e c t s   t h e   a m o unt   o w n e by   a   us e r .   H ow e v e r ,   i t h e   c o n t e xt   o f   CID S   w i t b l o c kc h a i n ,   s t a ke   i s   de f i n e a s   a   v a l ue   o f   r e put a t i o n   o f   a   n o de   o n   de t e c t i ng  a t t a c k s .   T hi s   r e pu t a t i o i s   m e a s u r e f r o m   t h e   de t e c t i o n   ra t e .   I n   o r de r   t o   pa r t i c i pa t e   i n   t h e   n e t w o r k,   n o de s   m us t   b e   a bl e   t o   pr o duc e   v a l i a t t a c s i g n a t u r e .   I n   P o A S   t h e   Evaluation Warning : The document was created with Spire.PDF for Python.
In do n e s i a J   E l e c   E ng  &   Co m S c i     IS S N :   2502 - 4752       D e s i gni ng  c ons e ns us   a l gor i t hm   f or   c ol l abor a t i v e   s i gn a t ur e - b as e i nt r us i on …  ( E k A r i p   W i nant o )   491   n u m b e r   o v a l i a t t a c s i g n a t u r e s   w i l l   be   us e a s   a   t hr e s h o l t o   i n di c a t e   t h e   r e pu t a t i o n   s c o r e .   T h e   r e put a t i o n   s c o r e   w i l l   de t e rm i n e   t h e   d i f f i c ul t y   of   h a s hi n g   puz z l e   a s   s h o w i T a b l e   2.     A ttac k   s i gn atu r e   v al i d ati o n   p r o c e s s .   T hi s   p r o c e s s   i s   t o   va l i da t e   a t t a c s i g n a t u r e   p r o po s e by   a   n o de .   T h e   v a l i d a t i o n   p r o c e s s   e xt e n s i o n   i s   r e qui r e f o r   CID S   t o   e n a b l e   n o de s   w o r ki n c o l l a b o r a t i v e l y   a n ha v i ng  c o n s e n t   by   its   p e e r .   I n   P o A S   v a l i da t i o n   o f   a t t a c s i gna t u r e   i s   do n e   by   de pl oy i n K - n e a r e s t   n e i g h b o r s   (K N N ).   K N N   m e a s u r e s   t h e   di s t a n c e   of   n - f e a t ur e   i n s t a n c e s   w h e r e   t h e   v a l ue   of   = (x 1 ,   x 2 . . .   x n r e p r e s e nt i n g   s e l e c t e t r a f f i c   h e a de r   f i e l ds .   M e a n w h i l e   i s   y =   ( y 1,   y 2. . .   y n r e p r e s e n t i n t h e   t r a f f i c   h e a de r   i n   l o c a l   s t o r a ge .   T h e   di s t a n c e   i s   c o m put e   a s   i t h e   f o l l ow i n e qu a t i o n :     ( , ) = ( 1 1 ) 2 + ( 2 2 ) 2 + + (   ) 2       P s e udoc o de   s h o w s   t h e   v a l i da t i o p r o c e s s   i n   P o A S .   T h e   pr o c e s s   r u n s   o n   e v e r y   n o de   t o   v a l i da t e   a t t a c s i g n a t u r e s   w h i c i s   p r o po s e by   a   n o de .   A t t a c s i g na t ur e   v a l i d a t i o n   p r o c e s s   a s   s h o w n   i F i gu r e   5.         F i gu r e   5 A t t a c k   s i g na t u r e   v a l i d a t i o p r o c e s s   P s e u d o c o d e   3 K N N   a l g o r i th m   i n   P o A S     Re a d   a t t a c k   s i g n a t u r e   f r o m   o t h e s t a k e s   i n t o   x ;   2   Re a d   a t t a c k   s i g n a t u r e   r e p o s i t o ry   i n t o   y   3   W ri t e   a rra y   t o   s t o re   d i s t a n c e     / *   M a i n   l o o p   * /   4   fo r   i   Є  y   do       fo r   j   Є  i   do   5     Co m p u t e   d i s t ( x , y )     6   A p p e n d   d i s t   i n t o   z   7   e n d   fo r   8   S o r t   t h e   z   d i s t a n c e s   b y   i n c r e a s i n g   o r d e r;   9   Co u n t   t h e   n u m b e o f   o c c u rr e n c e s   o c l a s s   a m o n g   k   n e a r e s t   n e i g h b o r s ;   10   A s s i g n   t o   x   t h e   m o s t   f re q u e n t   i n t o   c l a s s   a t t a c k ;       In   o r de r   v a l i d a t e   a t t a c s i g na t u r e   a l l   t h e   r e qui r e f i e l pa c k e t   h e a de r   a r e   c o n v e r t e i nt o   n u m e ri c   a s   s h o w n   i n   T a b l e   1.   T h e   p r o c e s s   of   t h i s   c o n v e r s i o n   do n e   i n   S t ri n g t o N um e r i c ()  f u n c t i o n   i n   ps e udo c o de   3.   A l l   s t ri n g   v a l ue   c o n v e r t e t o   n u m e ri c   by   A S CII  m a ppi ng  e xc e pt   pr o t o c o l   w h i c r e pr e s e nt   a s   i n t e ge r   num b e r.         T a b l e   1 E xa m p l e   r e s ul t   o f   c o n v e r t   a t t a c s i g n a t u r e     A t t a c k   s i g n a t u re   b e fo r e   c o n v e rt     A t t a c k   s i g n a t u re   a f t e c o n v e rt   p a c k e t   s i z e   f l a g s   T CP / U D P   s e g m e n t   l e n g t h   p ro t o c o l   h e a d e l e n g t h   p a c k e t   s i z e   f l a g s   T CP / U D P   s e g m e n t   l e n g t h   p ro t o c o l   h e a d e l e n g t h     U   A   R   S   F           U   A   R   S   F         1800   -   -   R   -   F   1760   t c p   40   1800       82     70   1760   1   40   340   -   -   -   S   -   300   t c p   40   340         83     300   1   40   510   -   -   -   -   -   480   u d p   40   510       -       480   0   40       D e te r m i n i n n o d e   r e p u tati o n In   o rde r   t o   de t e r m i n e   t h e   no de   r e put a t i o n   a l l   t h e   v a l i d a t i o n   r e s ul t s   f r o m   o t h e r   n o de s   h a v e   b e e n   c o l l e c t e d.   It   w i l l   p r o c e e t o   s o l v e   t h e   h a s h i ng  pu z z l e   i f   m a j o r i t y   of   n o de s   (m o r e   t h a n   50 %)  a g r e e   t ha t   t h e   p r o v i de s i gn a t u r e   i s   v a l i d.   O n   t h e   o t h e r   ha n w h e n   t h e   m a j o r i t y   of   n o de s   r e j e c t   t h e   pr o c e s s   w i l l   b e   s t o p.   F o r   a   s uc c e s s f ul   n o de   i t   w i l l   b e   r e w a r de a   c e r t a i n   r e pu t a t i o n   s c o r e .   T h e   c o l l e c t i v e   s c o r e   w i l l   de t e rm i n e   t h e   di f f i c ul t y   of   h a s h i n g   puz z l e   a s   s h o w n   i T a b l e   2.   I n   t hi s   e xa m pl e   a   p r e de t e rm i n e z e r di gi t   i n   e a c h   h a s h   v a l ue   r e qu i r e   n o de   t o   i de n t i fy   n o n c e .   A s   p r e de t e rm i n e z e r o   di gi t   i n c r e a s e   t h e   l e ve l   t o   f i n n o n c e   be c o m e   m o r e   di f f i c ul t .   T h i s   rul e   s h o w s   h i g n o de   r e put a t i o n   r e qu i r e s   l o w   c o m put a t i o n   w h i l e   l o w   n o de   r e put a t i o r e qui r e s   hi g c o m put a t i o t o   s o l v e   t h e   ha s hi n pu z z l e .     Bl o c k   ge n e r at i o n .   I n   t hi s   s t a ge ,   t h e   s uc c e s s f ul   n o de s   w i l l   ge n e r a t e   a   n e w   b l oc fo r   a dd i n da t a   i n   a   b l oc k.   T h e   v a l i d a t i o n   p r o c e s s   of  n e w   a t t a c s i gna t u r e   a n s o l v i n t h e   ha s h i n pu z z l e   w i l l   c o n t i n ue .   A   n o de   w i t h   hi g h   r e pu t a t i o h a s   a   b e t t e r   c h a n c e   t o   w i n   t h e   c o m pe t i t i o n   a nd  t hus   i t   w i l l   i n c r e a s e   t rus t   o f   r e put a b l e   n o de .   M e a n w hi l e   t h e   c o n s i s t e n c y   o f   da t a   c a b e   p r e s e r v e o n c e   t h e   d a t a   ha s   b e e n   i n pu t   i t h e   b l o c k.         Evaluation Warning : The document was created with Spire.PDF for Python.
                                IS S N :   2502 - 4752   In do n e s i a J   E l e c   E ng  &   Co m S c i ,   V o l .   22 ,   N o .   1 A p r i l   20 21   :     4 8 5   -   4 9 6   492   T a b l e   2 .   R e put a t i o t hr e s h o l v a l ue   id   Re p u t a t i o n   S a m p l e   t a rg e t   w i t h   i n i t i a l   n u l l   d i g i t   d e t e r m i n a t i o n   1   0 - 20   0 0 0 0 0 1 5 7 8 3 b 7 6 4 2 5 . . . . 4 8 f 4 6 a 3 3 f e 9 2 9 7 c f   2   21 - 40   0 0 0 0 1 5 7 8 3 b 7 6 4 2 5 7 . . . . 4 8 f 4 6 a 3 3 f e 9 2 9 7 c f   3   41 - 60   0 0 0 1 5 7 8 3 b 7 6 4 2 5 7 8 . . . . 4 8 f 4 6 a 3 3 f e 9 2 9 7 c f   4   61 - 80   0 0 1 5 7 8 3 b 7 6 4 2 5 7 8 9 . . . . 4 8 f 4 6 a 3 3 f e 9 2 9 7 c f   5   81 - 100   0 1 5 7 8 3 b 7 6 4 2 5 7 8 9 0 . . . . 4 8 f 4 6 a 3 3 f e 9 2 9 7 c       5.   EX P ER I M EN A N D   I N I TI A R ES U LT   5. 1 .       T e s tb e d   e n v i r o n m e n s e tu p   In   t hi s   s e c t i o n ,   w e   e v a l ua t e   t h e   pe r f o r m a n c e   o f   P o A S   u n de r   s o m e   a dv e r s a ri a l   s c e n a ri o s   i n   a   s i m ul a t e e n v i r o nm e nt   c o n s i s t   o f   fo ur t e e n   n o de s .   E l e v e n   no de s   a r e   a t t a c k - f r e e   n o de s ,   m e a n w h i l e   t h e   o t h e t hr e e   n o de s   a r e   h o s t i n s i m u l a t e i n s i de r   a t t a c ks   ( m a l i c i o us   n o de s a s   s h o w n   i n   F i gu r e   6 .   T h e s e   n o de s   a r e   v i r t u a l   m a c h i n e s   s e t up  i n   U b un t o pe ra t i ng  s y s t e m   c o n t a i n e r   w i t h   a   b l o c kc h a i n   pl a t f o r m   a nd  i n t rus i o de t e c t i o n   s y s t e m .   E a c h   n o de   ha s   t h e i r   o w n   l o c a l   a t t a c s i g n a t u r e   da t a b a s e   a n a t t a c s i g n a t u r e   da t a   s t o r e i b l oc kc h a i n.   B o t h   a t t a c s i g na t u r e   da t a   a r e   r e qui r e d   t o   de m o n s t r a t e   t h e   a b i l i t y   of  P o A S   t o   m a i nt a i n   a t t a c k   s i g n a t u r e   c o rr e c t n e s s   a nd  c o n s i s t e n c y   i n   b l o c kc h a i n.   I t hi s   e xpe r i m e nt   w e   e xt r a c t   CICID S 201 i nt r us i o n   de t e c t i o n   e v a l ua t i o da t a s e t   c o n s i s t   o f   ra w   n e t w o r t ra f f i c   pa c ke t   c a pt u r e i n   f i v e   c o n s e que n c e   d a y s   s t a r t e a t   a . m .   o n   M o n d a y ,   J ul y   a n e n de a t   p . m .   o n   F r i da y   J ul y   2017.   CICID S 2017  c o n t a i n s   b e n i g n   a n d   a t t a c t ra f f i c   da t a   i n c l ud i n F T P   a n S S H   B r ut e   F o r c e ,   D e n i a l   o f   S e r v i c e ,   H e a rt b l e e d,   P o r t   S c a n,   B o t n e t ,   D D o S   a n W e b   A t t a c k.   T h e r e   a r e   t w o   c a t e g o r i e s   o f   CICID S 2017  da t a   w hi c h   a r e   l a b e l e a n u nl a b e l e d   t r a f f i c   da t a .   T h e   l a b e l e t ra f f i c   da t a   c o n s i s t   o f   s pe c i f i c   a t t a c k   i n f o r m a t i o f o r   v a l i da t i o p r o c e s s .             F i gu r e   6 .   T h e   hi g h - l e v e l   a r c h i t e c t u r e   o f   e n v i r o nm e n t s   c o l l a b o r a t i v e   i n t r us i o n   de t e c t i o n   s y s t e m   w i t b l oc kc h a i n       A t t a c k   s i g na t u r e s   f r o m   l a b e l e CICID S 2017   da t a s e t   a r e   e xt ra c t e i n t o   14  p a r t s .   E a c h   pa rt   s t o r e i n   l o c a l   a t t a c s i g na t u r e   da t a b a s e   i n   e v e r y   n o de .   T hr e e   m a l i c i o us   n o de s   s i m u l a t e   i n s i de r   a t t a c ks   t ha t   a t t e m p t   t o   m o di fy   t h e   s i gna t u r e   d a t a .   M e a n w h i l e ,   o n   t h e   b l o c kc h a i n   p r o c e s s ,   P o A S   w i l l   i m p l e m e n t   c o n s e n s us   v a l i da t i o n   a n ha s h i n g   puz z l e   s o l ut i o n   b e fo r e   t h e   d a t a   c a n   b e   i n s e r t e i n   t h e   b l o c kc h a i n .   T h e n,   w e   o bs e r v e   t h e   r e s ul t   o i m p l e m e nt i ng  P o A S   o n   e ve r y   n o de   a n t h e i r   i m pl i c a t i o n   o de t e c t i o n   r a t e   i n   CID S   c o m pa r e w i t h   t h e   us a ge   of   n o rm a l   a t t a c k   s i g na t u r e   da t a b a s e .         Evaluation Warning : The document was created with Spire.PDF for Python.
In do n e s i a J   E l e c   E ng  &   Co m S c i     IS S N :   2502 - 4752       D e s i gni ng  c ons e ns us   a l gor i t hm   f or   c ol l abor a t i v e   s i gn a t ur e - b as e i nt r us i on …  ( E k A r i p   W i nant o )   493   5. 2 .       Ex p e r i m e n tal   r e s u l t   In   t h i s   e xpe r i m e n t   w e   m e a s ur e   t h e   de t e c t i o r a t e   of   e a c h   n o de   us i n n o r m a l   a t t a c s i g na t u r e   da t a b a s e   a n P o A S   a t t a c s i g na t u r e   b l o c kc h a i n.   S e c o n d,   w e   m e a s ur e   t h e   da t a   c o n s i s t e n c y   i n   b l o c k c h a i n   pr o c e s s ,   b e fo r e   a n a f t e r   da t a   e nt e r   t h e   b l oc k,   a n a f t e r   s i g n a t u r e   di s t ri b ut e   t o   t h e   o t h e r   n o de   i n   CID S .     F i gu r e   s h o w s   c o m pa ri s o n   o f   t h e   de t e c t i o r a t e   r e s ul t s   w i t h   P o A S   a n w i t h o ut   P o A S .   It   s h o w s   de t e c t i o n   r a t e   w i t h   P o A S   c o n s e n s us   a l go r i t h m   o b t a i n e hi g h e r   a c c ur a c y .   T h e   a t t e m pt   o i n s i de r   a t t a c c ha n g i n t h e   s i g n a t u r e s   i s   s uc c e s s f ul   o n   n o r m a l   s i g n a t u r e   da t a b a s e ,   m e a nw h i l e   P o A S   i s   a b l e   t o   pr e v e n t   t h e   c ha n ge s   f r o m   e n t e r i ng  b l o c k c h a i n   a nd  di s t ri b ut e   t h e   w r o n a t t a c s i g n a t u r e s   t o   t h e   o t h e r   n o de s   i n   CID S .   T h e   a t t a c k   s i g n a t u r e   s t o r e i b l o c kc h a i n   ha s   t o   ov e r c o m e   t r us t   i s s ue s   be t w e e n   n o de s .   O n   t h e   o t h e r   ha n d ,   C ID S   w i t h o ut   i m p l e m e nt i ng  P o A S   i s   n o t   a b l e   t o   p r e v e n t   i n s i de a t t a c ks   f r o m   c h a ngi n g   t h e   a t t a c s i g na t u r e s .     O n   t h e   s e c o n e xpe r i m e n t ,   w e   c o m pa r e   t h e   a t t a c s i g na t u r e   du ri n i m pl e m e n t i n P o A S   i n   t hr e e   s t a ge s .   F i r s t ,   t h e   a t t a c s i g n a t u r e   i n   a   n o de ,   s e c o n d,   t h e   a t t a c s i g n a t u r e   o v a l i d a t i o p r o c e s s ,   a n d   t hi r d ,   t h e   a t t a c s i g n a t u r e   i n   t h e   b l oc k.   T h i s   p r o c e s s   i s   t f i n o ut   t h e   l i s t   o a t t a c s i g na t u r e s   f r o m   t h e   i ni t i a l   p r o c e s s   unt i l   b l o c c r e a t e a r e   r e m a i n   c o n s i s t e nt .   F i g u r e   i s   a   c o m pa r i s o n   o f   a t t a c f e a t ur e s   i n   t w o   n o de s .   F i r s t   n o de   imp l e m e nt s   P o A S   a n t h e   s e c o n n o de   us i n a t t a c s i g n a t ur e   da t a b a s e .   T h e   gra p h   s h o w s   a t t a c s i gna t u r e s   a r e   c o n s i s t e nt   e v e n   i t h e   e xi s t e n c e   o f   i n s i de r   a t t a c ks   w i t h   P o A S .   In   t h e   s e c o n n o de   a t t a c s i g na t u r e s   a r e   i n c o n s i s t e n t   s i n c e   i n s i de r   a t t a c ke r s   c a n   m a ke   c h a n ge s   o a t t a c s i g na t u r e   a nd  t h i s   l e a d   t h e   n o de   c o n t r i b ut e   w r o n s i g n a t u r e s   t o   t h e   o t h e n o de   i n   CID S .             F i gu r e   7 .   Co m p a r i s o o f   A t t a c D e t e c t i o n   R a t e   (w i t a n w i t h o ut   P o A S )           F i gu r e   8 .   D a t a   Co n s i s t e n c y   o n   P o A S       F i gu r e   s h o w s   t h e   t i m e   di f f e r e n c e   fo r   P o A S   v a l i da t i o n   pr o c e s s   o n   e a c h   n o de .   T h e   o ut c o m e s   i n di c a t e   v a l i da t i o n   t i m e   i s   n o t   t h e   s a m e   fo r   e a c h   v a l i da t i o pr o c e s s   w h i c h   i n f l ue n c e s   by   t h e   s i z e   of  da t a s e t   a n v a l i da t i o m e t h o us e i e a c n o de .   F i gu r e   10  s h o w s   t h e   r e s ul t   o f   t i m e   c o m pa r i s o n   t o   s o l v e   h a s hi n g   Evaluation Warning : The document was created with Spire.PDF for Python.
                                IS S N :   2502 - 4752   In do n e s i a J   E l e c   E ng  &   Co m S c i ,   V o l .   22 ,   N o .   1 A p r i l   20 21   :     4 8 5   -   4 9 6   494   puz z l e   by   n o de s   w i t h   a   r e put a t i o n   s c o r e .   T h e   r e s ul t s   o f   t h e   a pp l i c a t i o n   o f   r e put a t i o n   s h o w   t h a t   t h e   v a l ue   o r e put a t i o a f f e c t s   t h e   pe r f o r m a n c e   o f   t h e   n o de   t o   c r e a t e   a   n e w   b l o c k.             F i gu r e   9 .   Co m p a r i s o o f   v a l i da t i o t i m e           F i gu r e   10 .   Co m pa ri s o n   o f   ha s h i ng  pu z z l e   s o l v i n g   t i m e       6.   C O N C LU S I O N     CID S   i s   a n   i m po rt a nt   s o l ut i o n   t o   i n c r e a s e   de t e c t i o n   ra t e   c o m pa r e w i t h   a   s i n g l e   n o de   ID S .   In   CID S   t h e   c o l l a b o r a t i v e   n o de s   c a n   s ha r e   a nd  v a l i da t e   a t t a c s i g n a t ur e .   H ow e v e r ,   e a c h   n o de   i s   s ub j e c t   t o   m a l i c i o us   a c t i v i t i e s   w h i c h   c a n   c r e a t e   i n v a l i s i g n a t u r e s   a n d   h a s   a   po t e nt i a l   t o   f o r m   u nt r us t e n e t w o r k.   F u rt h e rm o r e ,   t h e r e   i s   n o   s i n g l e   po i nt   o f   c o n t r o l   i n   di s t r i b ut e CID S   t o   m a i n t a i n   d a t a   c o n s i s t e n c y .   D ue   t o   t h e   n a t u r e   of  c r y pt oc urr e n c y   b l oc kc h a i n   o n   p r e s e r v i n t r a n s a c t i o n   i n   d i s t ri b ut e e n v i r o n m e nt s ,   t h e   i m p l e m e nt a t i o n   of  b l oc kc h a i n   c o n s e n s us   a l go r i t h m   i n   CID S   i s   v e r y   pr o m i s i n g .   In   t hi s   w o r k,   w e   h a v e   d e s i gn   a n   e xt e n s i o n   of  Cha i n - b a s e P oS   c o n s e n s us   a l go r i t h m   k n o w n   a s   P o A S   t o   be   i m pl e m e n t e i n   C ID S .   T h e   de s i g n   c o n s i s t s   o fo ur   e l e m e n t s   P o A S   i n c l udi n s t a ke   v a l ue   d e f i n i t i o n,   a t t a c k   s i gna t u r e   v a l i d a t i o n   p r o c e s s ,   de t e r m i ni n n o de   r e put a t i o n   a nd  b l o c k   ge n e r a t i o n .   W e   r u n   a n   e xpe r i m e nt   us i n CI CID S 2017  da t a   a n m e a s u r e   t h e   de t e c t i o n   ra t e ,   c o n s i s t e n c y   a n pe r f o r m a n c e .   T h e   r e s ul t   h a s   s h o w n   t ha t   P o A S   c a n   gua ra nt e e   t h e   c o n s i s t e n c y   of   a t t a c s i g n a t u r e   w h i c h   p r o v i de   by   n o de   ID S .   M o r e ov e r ,   P o A S   c a n   e nha n c e   t h e   t r us t   o t h e   a t t a c s i g n a t u r e   ge n e ra t e b y   t h e   n o de   w h i c h   a f fe c t s   a c c ur a c y   de t e c t i o n   i n   n o de   CID S   t hr o ug h   i de n t i f y i n u n t rut h f ul   i n pu t s   a n r e duc i ng  e rr o ra t e s .       Evaluation Warning : The document was created with Spire.PDF for Python.