SlideShare une entreprise Scribd logo
1  sur  14
Télécharger pour lire hors ligne
Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013
DOI : 10.5121/acij.2013.4203 27
RSA SIGNATURE: BEHIND THE SCENES
Dragan Vidakovic1
, Dusko Parezanovic1
, Olivera Nikolic2
and Jelena Kaljevic2
1
Gimnazija Ivanjica, Serbia
2
Faculty of Business Valjevo, Singidunum University Belgrade, Serbia
dragan.vidakovic@open.telekom.rs
infomat@open.telekom.rs
{onikolic,jkaljevic}@singidunum.ac.rs
ABSTRACT
In this paper, we present a complete digital signature message stream, just the way the RSA digital
signature scheme does it. We will focus on the operations with large numbers due to the fact that operating
with large numbers is the essence of RSA that cannot be understood by the usual illustrative examples with
small numbers[1].
KEYWORDS
Cryptography, Data Integrity, Digital Signature, Example
1. INTRODUCTION
The idea of RSA is based on the belief that it is difficult to factor the number that is the product
of two large prime numbers. Because of that it is necessary to develop the arithmetic of large
numbers operations, as well as to encode the algorithm for number primality test, a hash function
and many more auxiliary functions that are necessary for developing of the own digital signature
software[4].
Many people have heard about a digital signature and read a notice saying that a document is
digitally signed, but few of them have a real idea of what a digital signature is and how it looks
like.
Below, we will present in detail how to generate a digital signature. We are sure that this will be
an inspiring step for many people to try to develop their own tools for the protection of their data
integrity.
2. THE RSA SIGNATURE SCHEME
In this paragraph, we will recall the steps that are necessary for the RSA scheme [2][3].
Algorithm Key generation for the RSA signature scheme
SUMMARY: each entity creates an RSA public key and a corresponding private key.
Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013
28
Each entity A should do the following:
1. Generate two large distinct random primes p and q, each roughly the same size (see
x11.3.2).
2. Compute n = pq and = (p − 1)(q − 1).
3. Select a random integer e, 1 < e <  such that gcd(e, ) = 1.
4. Use the extended Euclidean algorithm ([2]) to compute the unique integer
d, 1 < d < , such that ed ≡1 (mod )
5. A’s public key is (n; e); A’s private key is d
Algorithm RSA signature generation and verification
SUMMARY: entity A signs a message m . Any entity B can verify A’s signature and
recover the message m from the signature.
1. Signature generation. Entity A should do the following:
(a) Compute m’ = R(m), an integer in the range [0; n − 1].
(b) Compute s = (m’)d
mod n.
(c) A’s signature for m is s.
2. Verification. To verify A’s signature s and recover the message m, B should:
(a) Obtain A’s authentic public key (n; e).
(b) Compute m’= se
mod n.
(c) Verify that m’ R; if not, reject the signature.
(d) Recover m = R−1(m’).
3. PREPARATORY STEP
In order to sign a message, we need to prepare many functions. Since Hash value of the message
is central in the digital signature, we consider it is very important that we have a software for
finding hash value.
In this paragraph, we will show the algotithm and code for SHA-1.
3.1. SECURE HASH ALGORITHM (SHA-1)
In this paragraph we specify SHA-1 [2], for several reasons: Because of the digital signature, to
see how seem complicated and daunting and in the end because we can see how it can be solved
by simply tools such as Delphi 7 console application.
INPUT: bitstring x of bitlength b≥0.
OUTPUT: 160-bit hash-code of x.
1. Definition of constans. Define a fifth (32-bit initial chaining values) IV to match those in
MD4: h5 = 0xc3d2e1f0. h5 = 0xc3d2e1f0.
Define per-round integer additive constants: y1 = 0x5a827999, y2 = 0x6ed9eba1,
y3 = 0x8f1bbcdc, y4 = 0xca62c1d6. (No order for accessing source words, or specification
of bit positions for left shifts is required.)
Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013
29
2. Overall preprocessing. Pad as in MD4, except the final two 32-bit words specifying
the bitlength b is appended with most significant word preceding least significant.
As in MD4, the formatted input is 16m 32-bit words: x0x1 … x16m−1. Initialize
chaining variables: (H1;H2;H3;H4;H5) ←(h1; h2; h3; h4; h5).
3. Processing. For each i from 0 to m − 1, copy the ith
block of sixteen 32-bit words
into temporary storage: X[j] ← x16i+j ; 0≤ j ≤ 15, and process these as below in
four 20-step rounds before updating the chaining variables
(expand 16-word block into 80-word block; let Xj denote X[j])
for j from 16 to 79, Xj  ((Xj-3(Xj-8 ⊕ Xj-14 ⊕ Xj-16)↵1).
(initialize working variables) (A, B, C, D, E)  (H1, H2, H3, H4, H5).
(Round 1) For j from 0 to 19 do the following:
t ((A↵5) + f(B, C, D) + E + Xj + y1),
(A, B, C, D, E)  (t, A, B↵30, C, D).
(Round 2) For j from 20 to 39 do the following
t ((A↵5) + h(B, C, D) + E + Xj + y2).
(A, B, C, D, E) (t, A, B↵30, C, D).
(Round 3) For j from 40 to 59 do the following:
t ((A↵5) + g(B,C,D) + E + Xj + y3)
(A, B, C, D, E)  (t, A, B↵30, C, D).
(Round 4) For j from 60 to 79 do the following:
t ((A↵5) + h(B, C, D) + E + Xj + y4).
(A, B, C, D, E)  (t, A, B↵30, C, D).
(update chaining values)
(H1, H2, H3, H4, H5)  (H1 + A, H2 + B, H3 + C, H4 + D, H5 + E).
4. Completion. The hash-value is: H1 & H2 & H3 & H4 & H5.
(with first and last bytes the high- and low-order bytes of H1, H5, respectively)
Where:
& : concatenation of strings
+ : addition modulo 232
f(u,v,w) = uv ∨ u’w
g(u,v,w) = uv ∨ uw ∨ vw
h(u,v,w) = u ⊕ v ⊕ w
uv: and
u’ : complement
u ∨ v : or
⊕: exclusive or
u ↵ s : rotation to the left for s position
(X1, . . . , Xj) ← (Y1, . . . , Yj) : simultaneous assignment (Xi ← Yi).
Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013
30
3.2. CODE FOR SHA-1
In this paragraph, we will encode upper algorithm. We will use console application Delphi 7.
PROGRAM SHA_1;
{$APPTYPE CONSOLE}
var c1: char;
k,i,j,l,duz,duz1,m,I1,I2,I3,I4:integer;
a:array[1..8] of integer;
a1,a2:array[1..32] of integer;
h1,h2,h3,h4,h5,y1,y2,y3,y4,hh1,hh2,hh3,hh4,hh5,p:array [0..31] of integer;
aa,bb,cc,dd,ee,pp,qq,rr,tt,ss,nn,mm:array[0..31] of integer;
pom:array[0..35] of integer;
x:array[0..79,0..31] of integer;
f,g:file of integer;
procedure dodeli(var a:array of integer;b:array of integer);
var i:integer;
begin
for i:=0 to 31 do a[i]:=b[i];
end;
procedure rot(var a:array of integer;t:integer);
var i,k,l:integer;
begin
for i:=1 to t do
begin
k:=a[0];
for l:=0 to 30 do a[l]:=a[l+1];
a[31]:=k;
end;
end;
procedure kom(var a:array of integer);
var i,j:integer;
begin
for i:=0 to 31 do
if a[i]=0 then a[i]:=1
else a[i]:=0;
end;
procedure fi(u,v,w:array of integer;var t:array of integer);
var i,j:integer;
p:array[0..31] of integer;
begin
for i:=0 to 31 do v[i]:=v[i] and u[i];
kom(u);
for i:=0 to 31 do t[i]:=v[i] or (u[i] and w[i]);
end;
procedure gi(u,v,w:array of integer;var t:array of integer);
var i,j:integer;
Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013
31
begin
for i:=0 to 31 do t[i]:=(u[i] and v[i]) or (u[i] and w[i]) or (v[i] and w[i]);
end;
procedure hi(u,v,w:array of integer;var t:array of integer);
var i,j:integer;
begin
for i:=0 to 31 do t[i]:=(u[i] xor v[i]) xor w[i];
end;
procedure saberi(a,b:array of integer;var w:array of integer);
var c:integer;
begin
c:=0;
for i:=31 downto 0 do
begin
w[i]:=(a[i]+b[i]+c) mod 2;
if (a[i]+b[i]+c)<2 then c:=0
else c:=1;
end;
end;
procedure ses(a,b,c,d:integer);
var s:integer;
begin
s:=0;
s:=a*8+b*4+c*2+d;
if s=0 then write('0');if s=1 then write('1');if s=2 then write('2');
if s=3 then write('3');if s=4 then write('4');if s=5 then write('5');
if s=6 then write('6');if s=7 then write('7');if s=8 then write('8');
if s=9 then write('9');if s=10 then write('a');if s=11 then write('b');
if s=12 then write('c');if s=13 then write('d');if s=14 then write('e');
if s=15 then write('f');
end;
begin
writeln;
writeln('Type your message to 147 symbols- because we use EOLN-Enter. For larger messages
we can use files');
assign(g,'por.dat');
rewrite(g);
duz:=0;
writeln;
write('Input message:');
while not eoln do
begin
read(c1);
k:=ord(c1);
for i:=1 to 8 do a[i]:=0;
i:=1;
while k<>0 do
begin
Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013
32
a[i]:=k mod 2;
k:=k div 2;
i:=i+1;
end;
duz:=duz+8;
for I:=8 downto 1 do write(g,A[I]);
end;
{Padding}
duz1:=duz;
k:=1;
l:=0;
write(g,k);
duz:=duz+1;
if duz mod 512=0 then
begin
for i:=1 to 512-64 do write(g,l);
duz:=duz+512-64;
end
else
begin
k:=duz mod 512;
for i:=1 to 512-k-64 do write(g,l);
duz:=duz+512-k-64;
end;
i:=1;
while duz1<>0 do
begin
if i<=32 then
begin
a1[i]:=duz1 mod 2;
duz1:=duz1 div 2
end
else
begin
a2[i]:=duz1 mod 2;
duz1:=duz1 div 2;
end;
i:=i+1;
end;
for i:=32 downto 1 do write(g,a2[i]);
for i:=32 downto 1 do write(g,a1[i]);
{big-endian }
{end of pading}
{Defining Constants}
{ Constants do not have to recalculate}
h1[31]:=1;h1[30]:=0;h1[29]:=0;h1[28]:=0; h1[27]:=0;h1[26]:=0;h1[25]:=0;h1[24]:=0;
h1[23]:=1;h1[22]:=1;h1[21]:=0;h1[20]:=0; h1[19]:=0;h1[18]:=1;h1[17]:=0;h1[16]:=0;
h1[15]:=1;h1[14]:=0;h1[13]:=1;h1[12]:=0; h1[11]:=0;h1[10]:=0;h1[9]:=1;h1[8]:=0;
Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013
33
h1[7]:=1;h1[6]:=1;h1[5]:=1;h1[4]:=0; h1[3]:=0;h1[2]:=1;h1[1]:=1;h1[0]:=0;
h2[31]:=1;h2[30]:=0;h2[29]:=0;h2[28]:=1; h2[27]:=0;h2[26]:=0;h2[25]:=0;h2[24]:=1;
h2[23]:=1;h2[22]:=1;h2[21]:=0;h2[20]:=1; h2[19]:=0;h2[18]:=1;h2[17]:=0;h2[16]:=1;
h2[15]:=1;h2[14]:=0;h2[13]:=1;h2[12]:=1; h2[11]:=0;h2[10]:=0;h2[9]:=1;h2[8]:=1;
h2[7]:=1;h2[6]:=1;h2[5]:=1;h2[4]:=1; h2[3]:=0;h2[2]:=1;h2[1]:=1;h2[0]:=1;
h3[31]:=0;h3[30]:=1;h3[29]:=1;h3[28]:=1; h3[27]:=1;h3[26]:=1;h3[25]:=1;h3[24]:=1;
h3[23]:=0;h3[22]:=0;h3[21]:=1;h3[20]:=1; h3[19]:=1;h3[18]:=0;h3[17]:=1;h3[16]:=1;
h3[15]:=0;h3[14]:=1;h3[13]:=0;h3[12]:=1; h3[11]:=1;h3[10]:=1;h3[9]:=0;h3[8]:=1;
h3[7]:=0;h3[6]:=0;h3[5]:=0;h3[4]:=1; h3[3]:=1;h3[2]:=0;h3[1]:=0;h3[0]:=1;
h4[31]:=0;h4[30]:=1;h4[29]:=1;h4[28]:=0; h4[27]:=1;h4[26]:=1;h4[25]:=1;h4[24]:=0;
h4[23]:=0;h4[22]:=0;h4[21]:=1;h4[20]:=0; h4[19]:=1;h4[18]:=0;h4[17]:=1;h4[16]:=0;
h4[15]:=0;h4[14]:=1;h4[13]:=0;h4[12]:=0; h4[11]:=1;h4[10]:=1;h4[9]:=0;h4[8]:=0;
h4[7]:=0;h4[6]:=0;h4[5]:=0;h4[4]:=0; h4[3]:=1;h4[2]:=0;h4[1]:=0;h4[0]:=0;
h5[31]:=0;h5[30]:=0;h5[29]:=0;h5[28]:=0; h5[27]:=1;h5[26]:=1;h5[25]:=1;h5[24]:=1;
h5[23]:=1;h5[22]:=0;h5[21]:=0;h5[20]:=0; h5[19]:=0;h5[18]:=1;h5[17]:=1;h5[16]:=1;
h5[15]:=0;h5[14]:=1;h5[13]:=0;h5[12]:=0; h5[11]:=1;h5[10]:=0;h5[9]:=1;h5[8]:=1;
h5[7]:=1;h5[6]:=1;h5[5]:=0;h5[4]:=0; h5[3]:=0;h5[2]:=0;h5[1]:=1;h5[0]:=1;
y1[31]:=1;y1[30]:=0;y1[29]:=0;y1[28]:=1; y1[27]:=1;y1[26]:=0;y1[25]:=0;y1[24]:=1;
y1[23]:=1;y1[22]:=0;y1[21]:=0;y1[20]:=1; y1[19]:=1;y1[18]:=1;y1[17]:=1;y1[16]:=0;
y1[15]:=0;y1[14]:=1;y1[13]:=0;y1[12]:=0; y1[11]:=0;y1[10]:=0;y1[9]:=0;y1[8]:=1;
y1[7]:=0;y1[6]:=1;y1[5]:=0;y1[4]:=1; y1[3]:=1;y1[2]:=0;y1[1]:=1;y1[0]:=0;
y2[31]:=1;y2[30]:=0;y2[29]:=0;y2[28]:=0; y2[27]:=0;y2[26]:=1;y2[25]:=0;y2[24]:=1;
y2[23]:=1;y2[22]:=1;y2[21]:=0;y2[20]:=1; y2[19]:=0;y2[18]:=1;y2[17]:=1;y2[16]:=1;
y2[15]:=1;y2[14]:=0;y2[13]:=0;y2[12]:=1; y2[11]:=1;y2[10]:=0;y2[9]:=1;y2[8]:=1;
y2[7]:=0;y2[6]:=1;y2[5]:=1;y2[4]:=1; y2[3]:=0;y2[2]:=1;y2[1]:=1;y2[0]:=0;
y3[31]:=0;y3[30]:=0;y3[29]:=1;y3[28]:=1; y3[27]:=1;y3[26]:=0;y3[25]:=1;y3[24]:=1;
y3[23]:=0;y3[22]:=0;y3[21]:=1;y3[20]:=1; y3[19]:=1;y3[18]:=1;y3[17]:=0;y3[16]:=1;
y3[15]:=1;y3[14]:=1;y3[13]:=0;y3[12]:=1; y3[11]:=1;y3[10]:=0;y3[9]:=0;y3[8]:=0;
y3[7]:=1;y3[6]:=1;y3[5]:=1;y3[4]:=1; y3[3]:=0;y3[2]:=0;y3[1]:=0;y3[0]:=1;
y4[31]:=0;y4[30]:=1;y4[29]:=1;y4[28]:=0; y4[27]:=1;y4[26]:=0;y4[25]:=1;y4[24]:=1;
y4[23]:=1;y4[22]:=0;y4[21]:=0;y4[20]:=0; y4[19]:=0;y4[18]:=0;y4[17]:=1;y4[16]:=1;
y4[15]:=0;y4[14]:=1;y4[13]:=0;y4[12]:=0; y4[11]:=0;y4[10]:=1;y4[9]:=1;y4[8]:=0;
y4[7]:=0;y4[6]:=1;y4[5]:=0;y4[4]:=1; y4[3]:=0;y4[2]:=0;y4[1]:=1;y4[0]:=1;
dodeli(hh1,h1);dodeli(hh2,h2);dodeli(hh3,h3); dodeli(hh4,h4);dodeli(hh5,h5);
m:=duz div 512;
reset(g);
{Processing}
i:=0;
while i<=m do
Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013
34
begin
for j:=0 to 15 do
begin
for l:=0 to 31 do
read(g,x[j,l]);
end;
for j:=16 to 79 do
begin
for l:=0 to 31 do
p[l]:=(((x[j-3,l] xor x[j-8,l]) xor x[j-14,l]) xor x[j-16,l]);
l:=1;
rot(p,l);
for l:=0 to 31 do x[j,l]:=p[l];
end;
i:=i+1;
end;
{initialize working variables}
dodeli(aa,hh1);dodeli(bb,hh2);dodeli(cc,hh3); dodeli(dd,hh4);dodeli(ee,hh5);
for j:=0 to 19 do
begin
dodeli(pp,aa); dodeli(ss,bb);
dodeli(nn,cc); dodeli(mm,dd);
for l:=0 to 31 do qq[l]:=x[j,l];
fi(bb,cc,dd,rr);
rot(aa,5);
saberi(aa,rr,pom);
saberi(pom,ee,pom);
saberi(pom,qq,pom);
saberi(pom,y1,pom);
for l:=0 to 31 do tt[l]:=pom[l];
dodeli(aa,tt);dodeli(bb,pp);
rot(ss,30);
dodeli(cc,ss);
dodeli(dd,nn);dodeli(ee,mm);
end; writeln;
for j:=20 to 39 do
begin
dodeli(pp,aa);dodeli(ss,bb);
dodeli(nn,cc);
dodeli(mm,dd);
for l:=0 to 31 do qq[l]:=x[j,l];
hi(bb,cc,dd,rr);
rot(aa,5);
saberi(aa,rr,pom);
saberi(pom,ee,pom);
saberi(pom,qq,pom);
saberi(pom,y2,pom);
for l:=0 to 31 do tt[l]:=pom[l];
Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013
35
dodeli(aa,tt);
dodeli(bb,pp);rot(ss,30);dodeli(cc,ss);dodeli(dd,nn); dodeli(ee,mm);
end;
for j:=40 to 59 do
begin
dodeli(pp,aa);dodeli(ss,bb);
dodeli(nn,cc); dodeli(mm,dd);
for l:=0 to 31 do qq[l]:=x[j,l];
gi(bb,cc,dd,rr);
rot(aa,5);
saberi(aa,rr,pom);
saberi(pom,ee,pom);
saberi(pom,qq,pom);
saberi(pom,y3,pom);
for l:=0 to 31 do tt[l]:=pom[l];
dodeli(aa,tt);
dodeli(bb,pp);rot(ss,30);dodeli(cc,ss);dodeli(dd,nn); dodeli(ee,mm);
end;
for j:=60 to 79 do
begin
dodeli(pp,aa);dodeli(ss,bb);
dodeli(nn,cc); dodeli(mm,dd);
for l:=0 to 31 do qq[l]:=x[j,l];
hi(bb,cc,dd,rr);
rot(aa,5);
saberi(aa,rr,pom);
saberi(pom,ee,pom);
saberi(pom,qq,pom);
saberi(pom,y4,pom);
for l:=0 to 31 do tt[l]:=pom[l];
dodeli(aa,tt);
dodeli(bb,pp);rot(ss,30);dodeli(cc,ss);dodeli(dd,nn); dodeli(ee,mm); end;
saberi(hh1,aa,pom);
for l:=0 to 31 do hh1[l]:=pom[l] ;
saberi(hh2,bb,pom);
for l:=0 to 31 do hh2[l]:=pom[l] ;
saberi(hh3,cc,pom);
for l:=0 to 31 do hh3[l]:=pom[l] ;
saberi(hh4,dd,pom);
for l:=0 to 31 do hh4[l]:=pom[l] ;
saberi(hh5,ee,pom);
for l:=0 to 31 do hh5[l]:=pom[l] ;
writeln('Binary Hash value:');
writeln;
for l:=0 to 31 do write(hh1[l]);
for l:=0 to 31 do write(hh2[l]);
for l:=0 to 31 do write(hh3[l]);
for l:=0 to 31 do write(hh4[l]);
Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013
36
for l:=0 to 31 do write(hh5[l]);
writeln;
assign(f,'hash.dat');
rewrite(f);
writeln('hex hash value:'); writeln;
for l:=31 downto 0 do write(f,hh5[l]);
for l:=31 downto 0 do write(f,hh4[l]);
for l:=31 downto 0 do write(f,hh3[l]);
for l:=31 downto 0 do write(f,hh2[l]);
for l:=31 downto 0 do write(f,hh1[l]);
for l:=0 to 7 do
begin
i1:=hh1[4*l];i2:=hh1[4*l+1];i3:=hh1[4*l+2]; i4:=hh1[4*l+3];
ses(i1,i2,i3,i4);
end;
for l:=0 to 7 do
begin
i1:=hh2[4*l];i2:=hh2[4*l+1];i3:=hh2[4*l+2]; i4:=hh2[4*l+3];
ses(i1,i2,i3,i4);
end;
for l:=0 to 7 do
begin
i1:=hh3[4*l];i2:=hh3[4*l+1];i3:=hh3[4*l+2]; i4:=hh3[4*l+3];
ses(i1,i2,i3,i4);
end;
for l:=0 to 7 do
begin
i1:=hh4[4*l];i2:=hh4[4*l+1];i3:=hh4[4*l+2]; i4:=hh4[4*l+3];
ses(i1,i2,i3,i4);
end;
for l:=0 to 7 do
begin
i1:=hh5[4*l];i2:=hh5[4*l+1];i3:=hh5[4*l+2]; i4:=hh5[4*l+3];
ses(i1,i2,i3,i4);
end; readln; readln;
end.
3.3. EXAMPLES OF HASH VALUES
The result of this function is the 160 series of zeros and ones whose order depends on the
message.
Examle 1: Using this software, we will determine the hash value of the message: Advanced
Computing: An International Journal (ACIJ)
Output to the screen:
Input message:Advanced Computing: An International Journal (ACIJ)
Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013
37
Binary Hash value:
101110111000000011110010011000000011110110000010010100111110010011110000110111
00
001101001111110101111010101001001101101001010001010001010010001101111001100001
01
hex hash value:
bb80f2603d8253e4f0dc34fd7aa4da5145237985
Example 2. If we left out (:) in message: Advanced Computing: An International Journal (ACIJ)
we get output to the screen:
Input message:Advanced Computing An International Journal (ACIJ)
Binary Hash value:
001000101000000011101010111001110111100110110111100001011101100000101111010000
00
010001110110000111011001001100011101110100010101000101001011000111000010100100
10
hex hash value:
2280eae779b785d82f404761d931dd1514b1c292
The omission of a single-letter hash value has undergone drastic changes. Undermined the
integrity of the message.
4. HOW DIGITAL SIGNATURE LOOK IN REALITY
In this paragraph, we will follow the steps of a message signing by the own software. It can be
found in [4].
The first step of a scheme is to detect two large (probably) prime numbers p and q, of
approximately the same number of digits. In this paper, we choose two 512-bit numbers that we
got by using our software realization of the Miler-Rabin algorithm.
Detected (probably) prime numbers are:
p:
100000000000000000000000000000000000000000000000000000000000000000000000000000
000000000000000000000000000000000000000000000000000000000000000000000000000000
000000000000000000000000000000000000000000000000000000000000000000000000000000
000000000000000000000010000000000000000000000000000000000000000000000000000000
000000000000000000000000000000000000000000000000000000000000000000000000100000
Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013
38
000000000000000000000100000000000000000000000000000000000000000000000001000000
00000000000000000000000000000000010110011101
q:
100000000000000000000000000000000000000000000000000000000000000000000000000000
000000000000000000000000000000000000000000000000000000000000000000000000000000
000000000000000000000000000000000000000000000000000000000000000000000000000000
000000000000000000000010000000000000000000000000000000000000000000000000000000
000000000000000000000000000000000000000000000000000000000000000000000000100000
000000000000000000000100000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000011110000011
Using our software from [3], we compute n= p*q as well as  = (p-1)*(q-1)
n=pq:
100000000000000000000000000000000000000000000000000000000000000000000000000000
000000000000000000000000000000000000000000000000000000000000000000000000000000
000000000000000000000000000000000000000000000000000000000000000000000000000000
000000000000000000000100000000000000000000000000000000000000000000000000000000
000000000000000000000000000000000000000000000000000000000000000000000001000000
000000000000000000001000000000000000000000000000000000000000000000000001000000
000000000000000000000000000000001101001000010000000000000000000000000000000000
000000000000000000000000000000000000000000000000000000000000000000000000000000
000000000000001000000000000000000000000001000000000000000000000000000000000000
000000000000001000000000000000000000000000000000000001101001000001000000000000
000000000000010000000000000000000000000001000000000000000000000010000000000000
000000000000010000000000011010010000000000000000000011010010000000000000000000
000000000000000000000000011110000011000000000000000000000000000010101000101010
01010111.
φ =(p-1)(q-1):
100000000000000000000000000000000000000000000000000000000000000000000000000000
000000000000000000000000000000000000000000000000000000000000000000000000000000
000000000000000000000000000000000000000000000000000000000000000000000000000000
000000000000000000000100000000000000000000000000000000000000000000000000000000
000000000000000000000000000000000000000000000000000000000000000000000001000000
000000000000000000001000000000000000000000000000000000000000000000000001000000
000000000000000000000000000000001101000111101000000000000000000000000000000000
000000000000000000000000000000000000000000000000000000000000000000000000000000
000000000000000100000000000000000000000000100000000000000000000000000000000000
000000000000000100000000000000000000000000000000000000110100011110100000000000
000000000000001000000000000000000000000000100000000000000000000001000000000000
000000000000001000000000001101000111100000000000000001101000111100000000000000
000000000000000000000000001111000001000000000000000000000000000001010100001110
100111000.
Then, we choose the public key, let’s assume e: 111, and using the same software we solve the
equation e*d≡ 1 (mod φ), or cryptographically said, we compute the private key[4][6][7].
Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013
39
d:
100100100100100100100100100100100100100100100100100100100100100100100100100100
100100100100100100100100100100100100100100100100100100100100100100100100100100
100100100100100100100100100100100100100100100100100100100100100100100100100100
100100100100100100101001001001001001001001001001001001001001001001001001001001
001001001001001001001001001001001001001001001001001001001001001001001010010010
010010010010010010011011011011011011011011011011011011011011011011011100100100
100100100100100100100100100100110011100100001001001001001001001001001001001001
001001001001001001001001001001001001001001001001001001001001001001001001001001
001001001001001101101101101101101101101110010010010010010010010010010010010010
010010010010010110110110110110110110110110110110110111110010110101001001001001
001001001001010010010010010010010010010010110110110110110110111000000000000000
000000000000001001001001011000001000100100100100100110011100100000000000000000
000000000000000000000000010001001010010010010010010010010010010011110010100010
111111.
Let “Elektrotehnicki fakultet u Beogradu” be the message we should sign. Its hash value is:
m:
00111111000111001010001001000111101110111010001100111111010000111100111110110001100001
1000110111010010010000100010100001001101110010010011100000101101000011011
The digital signature of a message m hash value is s= md
mod n.
s:
10111011000110000000011100010001100101111111010011100110101001100101000010111001010000
01100101101011101100011100001011111111100000100100011000001010001110111110000100100100
00011100001101000100011100011110000101101010100110100100111111000111000110000001110011
11010101010000111111001011011111110100011100110010110010011000110011100000010111100110
00010111100000101001011011100010000011000101000011000101100011011011100011011101101101
00111110010100001001011001110011001010010100100011010001000011111101011001110011010100
11011100001100111111101110100101110100010110101111101100001011100001010001010001011101
11000100110100011000110000110001010000100010110101011100010001001100010111011111011110
01000001000010111000001111011011000000001111100001110011110101110111111011111011000000
11111100010011010000100111111110111010101011110010110110011111111011110110111110110110
00011011001100111101100011101110110111100001011011000010000000111101010101000011010101
1001011100100001010101010100110011010111110110101101110111110110000110101001.
If we check it, we get m’= se
mod n.
m’
:
00111111000111001010001001000111101110111010001100111111010000111100111110110001100001
10001101110100100100001000101000010011011100100100111000001011010000110110.
By this, we are sure that using the previous operation, we really get the same value (m=m’). it
means that the data integrity is preserved and that the owner of a private key is the one who
signed the message.
Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013
40
5. FUTURE WORK
In the arguments for and against in a trial of strength of ECC (Elliptic Curve Cryptography)
and RSA, the simple fact that they are performed by the same tools made for operations with
large numbers, is usually overlooked. Mathematical bases of RSA and ECC are completely
different [2] [8], but they need the same operations: addition, subtraction, multiplication, division,
finding the remainder, calculating d from the equation e*d ≡ 1 (mod p) for fixed values of e and
p, SHA-1 and more other joint auxiliary operations needed for the realization of a digital
signature in both schemes. Therefore, ECC is our next goal-because we have the tools.
6. CONCLUSION
We believe that each country must stimulate young people’s interest in cryptography, because we
doubt that our secret data can be protected using someone else’s software.
Of course, it is very difficult to develop our own protection mechanisms, but we think it is far
better to protect data using our own mechanisms first, and then, thus modified, leave them to
someone else’s software, than to allow the original data be protected by somebody else’s
mechanisms, which is a logical nonsense.
That is the reason why we always insist on more our own softwares and a greater interest in
cryptography, which seems itself (in case it wasn’t brought closer to a reader) pretty cryptic and
bouncing[5]. So, this work is primarily addressed to young researches as an incentive to try to
develop their own tools for data protection. Those tools do not have to be flawless, they may be
far below the level of the tools found on the market. However, they should be good enough for
the beginning of a hard work that would lead researches to some great commercial solutions.
REFERENCES
[1] D.Vidakovic, O. Nikolic, D. Parezanovic, “Acceleration Detection of Large (Probably) Prime
Numbers”, International Journal of UbiComp (IJU), Vol.4, No.1, January 2013
[2] A. Menezes, P.C. van Oorschot, S. Vanstone, Handbook of Applied Cryptography, CRC Press, New
York, 1997.
[3] B. Schneier, Applied Cryptography, John Wiley & Sons, New York, 1996.
[4] D. Vidaković, “Analysis and implementation of asymmetric algorithms for data secrecy and integrity
protection”, Master Thesis (mentor Jovan Golic), Faculty of Electrical Engineering, Belgrade 1999.
[5] D. Vidakovic, D. Simic, “A Novel Approach To Building Secure Systems“, ARES 2007, Vienna,
Austria, pp 1074-1084.
[6] C. Zhang, “An improved binary algorithm for RSA”, Computers and Mathematics with Applications,
25:6 (1993), 15–24.
[7] S.-M. Hong, S.-Y. OH, and H. Yoon, “New modular multiplication algorithms for fast modular
exponentiation”, Advances in Cryptology–EUROCRYPT ’96 (LNCS 1070), 166–177, 1996
[8] N. Koblitz, “Elliptic Curve Cryptosystems”, Mathematics of Computations, 48, pp. 203-209, 1987.

Contenu connexe

Tendances

Line drawing algorithm
Line drawing algorithmLine drawing algorithm
Line drawing algorithmA. S. M. Shafi
 
An Introduction to Coding Theory
An Introduction to Coding TheoryAn Introduction to Coding Theory
An Introduction to Coding TheoryAlexanderWei11
 
20101017 program analysis_for_security_livshits_lecture02_compilers
20101017 program analysis_for_security_livshits_lecture02_compilers20101017 program analysis_for_security_livshits_lecture02_compilers
20101017 program analysis_for_security_livshits_lecture02_compilersComputer Science Club
 
Security of RSA and Integer Factorization
Security of RSA and Integer FactorizationSecurity of RSA and Integer Factorization
Security of RSA and Integer FactorizationDharmalingam Ganesan
 
A verifiable random function with short proofs and keys
A verifiable random function with short proofs and keysA verifiable random function with short proofs and keys
A verifiable random function with short proofs and keysAleksandr Yampolskiy
 
Dependency Analysis of RSA Private Variables
Dependency Analysis of RSA Private VariablesDependency Analysis of RSA Private Variables
Dependency Analysis of RSA Private VariablesDharmalingam Ganesan
 
Solutions to online rsa factoring challenges
Solutions to online rsa factoring challengesSolutions to online rsa factoring challenges
Solutions to online rsa factoring challengesDharmalingam Ganesan
 
Cyclic Attacks on the RSA Trapdoor Function
Cyclic Attacks on the RSA Trapdoor FunctionCyclic Attacks on the RSA Trapdoor Function
Cyclic Attacks on the RSA Trapdoor FunctionDharmalingam Ganesan
 
Nonlinear analysis of fixed support beam with hinge by hinge method in c prog...
Nonlinear analysis of fixed support beam with hinge by hinge method in c prog...Nonlinear analysis of fixed support beam with hinge by hinge method in c prog...
Nonlinear analysis of fixed support beam with hinge by hinge method in c prog...Salar Delavar Qashqai
 
Broadcasting and low exponent rsa attack
Broadcasting and low exponent rsa attackBroadcasting and low exponent rsa attack
Broadcasting and low exponent rsa attackAnkita Kapratwar
 
Defense Senior College on Error Coding presentation 4/22/2010
Defense Senior College on Error Coding presentation 4/22/2010Defense Senior College on Error Coding presentation 4/22/2010
Defense Senior College on Error Coding presentation 4/22/2010Felicia Fort, MBA
 
An Analysis of Secure Remote Password (SRP)
An Analysis of Secure Remote Password (SRP)An Analysis of Secure Remote Password (SRP)
An Analysis of Secure Remote Password (SRP)Dharmalingam Ganesan
 

Tendances (20)

2D array
2D array2D array
2D array
 
Line drawing algorithm
Line drawing algorithmLine drawing algorithm
Line drawing algorithm
 
An Introduction to Coding Theory
An Introduction to Coding TheoryAn Introduction to Coding Theory
An Introduction to Coding Theory
 
20101017 program analysis_for_security_livshits_lecture02_compilers
20101017 program analysis_for_security_livshits_lecture02_compilers20101017 program analysis_for_security_livshits_lecture02_compilers
20101017 program analysis_for_security_livshits_lecture02_compilers
 
Security of RSA and Integer Factorization
Security of RSA and Integer FactorizationSecurity of RSA and Integer Factorization
Security of RSA and Integer Factorization
 
A verifiable random function with short proofs and keys
A verifiable random function with short proofs and keysA verifiable random function with short proofs and keys
A verifiable random function with short proofs and keys
 
Dependency Analysis of RSA Private Variables
Dependency Analysis of RSA Private VariablesDependency Analysis of RSA Private Variables
Dependency Analysis of RSA Private Variables
 
Rsa
RsaRsa
Rsa
 
Solutions to online rsa factoring challenges
Solutions to online rsa factoring challengesSolutions to online rsa factoring challenges
Solutions to online rsa factoring challenges
 
RSA cracking puzzle
RSA cracking puzzleRSA cracking puzzle
RSA cracking puzzle
 
Cyclic Attacks on the RSA Trapdoor Function
Cyclic Attacks on the RSA Trapdoor FunctionCyclic Attacks on the RSA Trapdoor Function
Cyclic Attacks on the RSA Trapdoor Function
 
RSA without Padding
RSA without PaddingRSA without Padding
RSA without Padding
 
Nonlinear analysis of fixed support beam with hinge by hinge method in c prog...
Nonlinear analysis of fixed support beam with hinge by hinge method in c prog...Nonlinear analysis of fixed support beam with hinge by hinge method in c prog...
Nonlinear analysis of fixed support beam with hinge by hinge method in c prog...
 
Broadcasting and low exponent rsa attack
Broadcasting and low exponent rsa attackBroadcasting and low exponent rsa attack
Broadcasting and low exponent rsa attack
 
Defense Senior College on Error Coding presentation 4/22/2010
Defense Senior College on Error Coding presentation 4/22/2010Defense Senior College on Error Coding presentation 4/22/2010
Defense Senior College on Error Coding presentation 4/22/2010
 
RSA Two Person Game
RSA Two Person GameRSA Two Person Game
RSA Two Person Game
 
Bitcoin Script
Bitcoin ScriptBitcoin Script
Bitcoin Script
 
An Analysis of Secure Remote Password (SRP)
An Analysis of Secure Remote Password (SRP)An Analysis of Secure Remote Password (SRP)
An Analysis of Secure Remote Password (SRP)
 
Midterm sols
Midterm solsMidterm sols
Midterm sols
 
Digi qestions
Digi qestionsDigi qestions
Digi qestions
 

Similaire à RSA SIGNATURE: BEHIND THE SCENES

A Signature Algorithm Based On Chaotic Maps And Factoring Problems
A Signature Algorithm Based On Chaotic Maps And Factoring ProblemsA Signature Algorithm Based On Chaotic Maps And Factoring Problems
A Signature Algorithm Based On Chaotic Maps And Factoring ProblemsSandra Long
 
01 - DAA - PPT.pptx
01 - DAA - PPT.pptx01 - DAA - PPT.pptx
01 - DAA - PPT.pptxKokilaK25
 
Design of QSD Number System Addition using Delayed Addition Technique
Design of QSD Number System Addition using Delayed Addition TechniqueDesign of QSD Number System Addition using Delayed Addition Technique
Design of QSD Number System Addition using Delayed Addition TechniqueKumar Goud
 
Design of QSD Number System Addition using Delayed Addition Technique
Design of QSD Number System Addition using Delayed Addition TechniqueDesign of QSD Number System Addition using Delayed Addition Technique
Design of QSD Number System Addition using Delayed Addition TechniqueKumar Goud
 
Identity-based threshold group signature scheme based on multiple hard number...
Identity-based threshold group signature scheme based on multiple hard number...Identity-based threshold group signature scheme based on multiple hard number...
Identity-based threshold group signature scheme based on multiple hard number...IJECEIAES
 
Mouse programming in c
Mouse programming in cMouse programming in c
Mouse programming in cgkgaur1987
 
COMPUTER GRAPHICS LAB MANUAL
COMPUTER GRAPHICS LAB MANUALCOMPUTER GRAPHICS LAB MANUAL
COMPUTER GRAPHICS LAB MANUALVivek Kumar Sinha
 
Security of Artificial Intelligence
Security of Artificial IntelligenceSecurity of Artificial Intelligence
Security of Artificial IntelligenceFederico Cerutti
 
Georgy Nosenko - An introduction to the use SMT solvers for software security
Georgy Nosenko - An introduction to the use SMT solvers for software securityGeorgy Nosenko - An introduction to the use SMT solvers for software security
Georgy Nosenko - An introduction to the use SMT solvers for software securityDefconRussia
 
CD504 CGM_Lab Manual_004e08d3838702ed11fc6d03cc82f7be.pdf
CD504 CGM_Lab Manual_004e08d3838702ed11fc6d03cc82f7be.pdfCD504 CGM_Lab Manual_004e08d3838702ed11fc6d03cc82f7be.pdf
CD504 CGM_Lab Manual_004e08d3838702ed11fc6d03cc82f7be.pdfRajJain516913
 
Coding theory.pdf
Coding theory.pdfCoding theory.pdf
Coding theory.pdf230231060
 
Shad_Cryptography_PracticalFile_IT_4th_Year (1).docx
Shad_Cryptography_PracticalFile_IT_4th_Year (1).docxShad_Cryptography_PracticalFile_IT_4th_Year (1).docx
Shad_Cryptography_PracticalFile_IT_4th_Year (1).docxSonu62614
 
Computer graphics lab manual
Computer graphics lab manualComputer graphics lab manual
Computer graphics lab manualUma mohan
 
Advance data structure & algorithm
Advance data structure & algorithmAdvance data structure & algorithm
Advance data structure & algorithmK Hari Shankar
 

Similaire à RSA SIGNATURE: BEHIND THE SCENES (20)

A Signature Algorithm Based On Chaotic Maps And Factoring Problems
A Signature Algorithm Based On Chaotic Maps And Factoring ProblemsA Signature Algorithm Based On Chaotic Maps And Factoring Problems
A Signature Algorithm Based On Chaotic Maps And Factoring Problems
 
01 - DAA - PPT.pptx
01 - DAA - PPT.pptx01 - DAA - PPT.pptx
01 - DAA - PPT.pptx
 
Design of QSD Number System Addition using Delayed Addition Technique
Design of QSD Number System Addition using Delayed Addition TechniqueDesign of QSD Number System Addition using Delayed Addition Technique
Design of QSD Number System Addition using Delayed Addition Technique
 
Design of QSD Number System Addition using Delayed Addition Technique
Design of QSD Number System Addition using Delayed Addition TechniqueDesign of QSD Number System Addition using Delayed Addition Technique
Design of QSD Number System Addition using Delayed Addition Technique
 
Identity-based threshold group signature scheme based on multiple hard number...
Identity-based threshold group signature scheme based on multiple hard number...Identity-based threshold group signature scheme based on multiple hard number...
Identity-based threshold group signature scheme based on multiple hard number...
 
Mouse programming in c
Mouse programming in cMouse programming in c
Mouse programming in c
 
COMPUTER GRAPHICS LAB MANUAL
COMPUTER GRAPHICS LAB MANUALCOMPUTER GRAPHICS LAB MANUAL
COMPUTER GRAPHICS LAB MANUAL
 
Security of Artificial Intelligence
Security of Artificial IntelligenceSecurity of Artificial Intelligence
Security of Artificial Intelligence
 
Georgy Nosenko - An introduction to the use SMT solvers for software security
Georgy Nosenko - An introduction to the use SMT solvers for software securityGeorgy Nosenko - An introduction to the use SMT solvers for software security
Georgy Nosenko - An introduction to the use SMT solvers for software security
 
CD504 CGM_Lab Manual_004e08d3838702ed11fc6d03cc82f7be.pdf
CD504 CGM_Lab Manual_004e08d3838702ed11fc6d03cc82f7be.pdfCD504 CGM_Lab Manual_004e08d3838702ed11fc6d03cc82f7be.pdf
CD504 CGM_Lab Manual_004e08d3838702ed11fc6d03cc82f7be.pdf
 
Coding theory.pdf
Coding theory.pdfCoding theory.pdf
Coding theory.pdf
 
Shad_Cryptography_PracticalFile_IT_4th_Year (1).docx
Shad_Cryptography_PracticalFile_IT_4th_Year (1).docxShad_Cryptography_PracticalFile_IT_4th_Year (1).docx
Shad_Cryptography_PracticalFile_IT_4th_Year (1).docx
 
C lab excellent
C lab excellentC lab excellent
C lab excellent
 
C and Data Structures Lab Solutions
C and Data Structures Lab SolutionsC and Data Structures Lab Solutions
C and Data Structures Lab Solutions
 
C and Data Structures
C and Data Structures C and Data Structures
C and Data Structures
 
Computer graphics lab manual
Computer graphics lab manualComputer graphics lab manual
Computer graphics lab manual
 
Lecture 1 mte 407
Lecture 1 mte 407Lecture 1 mte 407
Lecture 1 mte 407
 
Lecture 1 mte 407
Lecture 1 mte 407Lecture 1 mte 407
Lecture 1 mte 407
 
Mcs 011 solved assignment 2015-16
Mcs 011 solved assignment 2015-16Mcs 011 solved assignment 2015-16
Mcs 011 solved assignment 2015-16
 
Advance data structure & algorithm
Advance data structure & algorithmAdvance data structure & algorithm
Advance data structure & algorithm
 

Plus de acijjournal

Jan_2024_Top_read_articles_in_ACIJ.pdf
Jan_2024_Top_read_articles_in_ACIJ.pdfJan_2024_Top_read_articles_in_ACIJ.pdf
Jan_2024_Top_read_articles_in_ACIJ.pdfacijjournal
 
Call for Papers - Advanced Computing An International Journal (ACIJ) (2).pdf
Call for Papers - Advanced Computing An International Journal (ACIJ) (2).pdfCall for Papers - Advanced Computing An International Journal (ACIJ) (2).pdf
Call for Papers - Advanced Computing An International Journal (ACIJ) (2).pdfacijjournal
 
cs - ACIJ (4) (1).pdf
cs - ACIJ (4) (1).pdfcs - ACIJ (4) (1).pdf
cs - ACIJ (4) (1).pdfacijjournal
 
cs - ACIJ (2).pdf
cs - ACIJ (2).pdfcs - ACIJ (2).pdf
cs - ACIJ (2).pdfacijjournal
 
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)acijjournal
 
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)acijjournal
 
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)acijjournal
 
4thInternational Conference on Machine Learning & Applications (CMLA 2022)
4thInternational Conference on Machine Learning & Applications (CMLA 2022)4thInternational Conference on Machine Learning & Applications (CMLA 2022)
4thInternational Conference on Machine Learning & Applications (CMLA 2022)acijjournal
 
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)acijjournal
 
3rdInternational Conference on Natural Language Processingand Applications (N...
3rdInternational Conference on Natural Language Processingand Applications (N...3rdInternational Conference on Natural Language Processingand Applications (N...
3rdInternational Conference on Natural Language Processingand Applications (N...acijjournal
 
4thInternational Conference on Machine Learning & Applications (CMLA 2022)
4thInternational Conference on Machine Learning & Applications (CMLA 2022)4thInternational Conference on Machine Learning & Applications (CMLA 2022)
4thInternational Conference on Machine Learning & Applications (CMLA 2022)acijjournal
 
Graduate School Cyber Portfolio: The Innovative Menu For Sustainable Development
Graduate School Cyber Portfolio: The Innovative Menu For Sustainable DevelopmentGraduate School Cyber Portfolio: The Innovative Menu For Sustainable Development
Graduate School Cyber Portfolio: The Innovative Menu For Sustainable Developmentacijjournal
 
Genetic Algorithms and Programming - An Evolutionary Methodology
Genetic Algorithms and Programming - An Evolutionary MethodologyGenetic Algorithms and Programming - An Evolutionary Methodology
Genetic Algorithms and Programming - An Evolutionary Methodologyacijjournal
 
Data Transformation Technique for Protecting Private Information in Privacy P...
Data Transformation Technique for Protecting Private Information in Privacy P...Data Transformation Technique for Protecting Private Information in Privacy P...
Data Transformation Technique for Protecting Private Information in Privacy P...acijjournal
 
Advanced Computing: An International Journal (ACIJ)
Advanced Computing: An International Journal (ACIJ) Advanced Computing: An International Journal (ACIJ)
Advanced Computing: An International Journal (ACIJ) acijjournal
 
E-Maintenance: Impact Over Industrial Processes, Its Dimensions & Principles
E-Maintenance: Impact Over Industrial Processes, Its Dimensions & PrinciplesE-Maintenance: Impact Over Industrial Processes, Its Dimensions & Principles
E-Maintenance: Impact Over Industrial Processes, Its Dimensions & Principlesacijjournal
 
10th International Conference on Software Engineering and Applications (SEAPP...
10th International Conference on Software Engineering and Applications (SEAPP...10th International Conference on Software Engineering and Applications (SEAPP...
10th International Conference on Software Engineering and Applications (SEAPP...acijjournal
 
10th International conference on Parallel, Distributed Computing and Applicat...
10th International conference on Parallel, Distributed Computing and Applicat...10th International conference on Parallel, Distributed Computing and Applicat...
10th International conference on Parallel, Distributed Computing and Applicat...acijjournal
 
DETECTION OF FORGERY AND FABRICATION IN PASSPORTS AND VISAS USING CRYPTOGRAPH...
DETECTION OF FORGERY AND FABRICATION IN PASSPORTS AND VISAS USING CRYPTOGRAPH...DETECTION OF FORGERY AND FABRICATION IN PASSPORTS AND VISAS USING CRYPTOGRAPH...
DETECTION OF FORGERY AND FABRICATION IN PASSPORTS AND VISAS USING CRYPTOGRAPH...acijjournal
 
Detection of Forgery and Fabrication in Passports and Visas Using Cryptograph...
Detection of Forgery and Fabrication in Passports and Visas Using Cryptograph...Detection of Forgery and Fabrication in Passports and Visas Using Cryptograph...
Detection of Forgery and Fabrication in Passports and Visas Using Cryptograph...acijjournal
 

Plus de acijjournal (20)

Jan_2024_Top_read_articles_in_ACIJ.pdf
Jan_2024_Top_read_articles_in_ACIJ.pdfJan_2024_Top_read_articles_in_ACIJ.pdf
Jan_2024_Top_read_articles_in_ACIJ.pdf
 
Call for Papers - Advanced Computing An International Journal (ACIJ) (2).pdf
Call for Papers - Advanced Computing An International Journal (ACIJ) (2).pdfCall for Papers - Advanced Computing An International Journal (ACIJ) (2).pdf
Call for Papers - Advanced Computing An International Journal (ACIJ) (2).pdf
 
cs - ACIJ (4) (1).pdf
cs - ACIJ (4) (1).pdfcs - ACIJ (4) (1).pdf
cs - ACIJ (4) (1).pdf
 
cs - ACIJ (2).pdf
cs - ACIJ (2).pdfcs - ACIJ (2).pdf
cs - ACIJ (2).pdf
 
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
 
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
 
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
 
4thInternational Conference on Machine Learning & Applications (CMLA 2022)
4thInternational Conference on Machine Learning & Applications (CMLA 2022)4thInternational Conference on Machine Learning & Applications (CMLA 2022)
4thInternational Conference on Machine Learning & Applications (CMLA 2022)
 
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
7thInternational Conference on Data Mining & Knowledge Management (DaKM 2022)
 
3rdInternational Conference on Natural Language Processingand Applications (N...
3rdInternational Conference on Natural Language Processingand Applications (N...3rdInternational Conference on Natural Language Processingand Applications (N...
3rdInternational Conference on Natural Language Processingand Applications (N...
 
4thInternational Conference on Machine Learning & Applications (CMLA 2022)
4thInternational Conference on Machine Learning & Applications (CMLA 2022)4thInternational Conference on Machine Learning & Applications (CMLA 2022)
4thInternational Conference on Machine Learning & Applications (CMLA 2022)
 
Graduate School Cyber Portfolio: The Innovative Menu For Sustainable Development
Graduate School Cyber Portfolio: The Innovative Menu For Sustainable DevelopmentGraduate School Cyber Portfolio: The Innovative Menu For Sustainable Development
Graduate School Cyber Portfolio: The Innovative Menu For Sustainable Development
 
Genetic Algorithms and Programming - An Evolutionary Methodology
Genetic Algorithms and Programming - An Evolutionary MethodologyGenetic Algorithms and Programming - An Evolutionary Methodology
Genetic Algorithms and Programming - An Evolutionary Methodology
 
Data Transformation Technique for Protecting Private Information in Privacy P...
Data Transformation Technique for Protecting Private Information in Privacy P...Data Transformation Technique for Protecting Private Information in Privacy P...
Data Transformation Technique for Protecting Private Information in Privacy P...
 
Advanced Computing: An International Journal (ACIJ)
Advanced Computing: An International Journal (ACIJ) Advanced Computing: An International Journal (ACIJ)
Advanced Computing: An International Journal (ACIJ)
 
E-Maintenance: Impact Over Industrial Processes, Its Dimensions & Principles
E-Maintenance: Impact Over Industrial Processes, Its Dimensions & PrinciplesE-Maintenance: Impact Over Industrial Processes, Its Dimensions & Principles
E-Maintenance: Impact Over Industrial Processes, Its Dimensions & Principles
 
10th International Conference on Software Engineering and Applications (SEAPP...
10th International Conference on Software Engineering and Applications (SEAPP...10th International Conference on Software Engineering and Applications (SEAPP...
10th International Conference on Software Engineering and Applications (SEAPP...
 
10th International conference on Parallel, Distributed Computing and Applicat...
10th International conference on Parallel, Distributed Computing and Applicat...10th International conference on Parallel, Distributed Computing and Applicat...
10th International conference on Parallel, Distributed Computing and Applicat...
 
DETECTION OF FORGERY AND FABRICATION IN PASSPORTS AND VISAS USING CRYPTOGRAPH...
DETECTION OF FORGERY AND FABRICATION IN PASSPORTS AND VISAS USING CRYPTOGRAPH...DETECTION OF FORGERY AND FABRICATION IN PASSPORTS AND VISAS USING CRYPTOGRAPH...
DETECTION OF FORGERY AND FABRICATION IN PASSPORTS AND VISAS USING CRYPTOGRAPH...
 
Detection of Forgery and Fabrication in Passports and Visas Using Cryptograph...
Detection of Forgery and Fabrication in Passports and Visas Using Cryptograph...Detection of Forgery and Fabrication in Passports and Visas Using Cryptograph...
Detection of Forgery and Fabrication in Passports and Visas Using Cryptograph...
 

Dernier

input buffering in lexical analysis in CD
input buffering in lexical analysis in CDinput buffering in lexical analysis in CD
input buffering in lexical analysis in CDHeadOfDepartmentComp1
 
Triangulation survey (Basic Mine Surveying)_MI10412MI.pptx
Triangulation survey (Basic Mine Surveying)_MI10412MI.pptxTriangulation survey (Basic Mine Surveying)_MI10412MI.pptx
Triangulation survey (Basic Mine Surveying)_MI10412MI.pptxRomil Mishra
 
Detection&Tracking - Thermal imaging object detection and tracking
Detection&Tracking - Thermal imaging object detection and trackingDetection&Tracking - Thermal imaging object detection and tracking
Detection&Tracking - Thermal imaging object detection and trackinghadarpinhas1
 
Livre Implementing_Six_Sigma_and_Lean_A_prac([Ron_Basu]_).pdf
Livre Implementing_Six_Sigma_and_Lean_A_prac([Ron_Basu]_).pdfLivre Implementing_Six_Sigma_and_Lean_A_prac([Ron_Basu]_).pdf
Livre Implementing_Six_Sigma_and_Lean_A_prac([Ron_Basu]_).pdfsaad175691
 
Stork Webinar | APM Transformational planning, Tool Selection & Performance T...
Stork Webinar | APM Transformational planning, Tool Selection & Performance T...Stork Webinar | APM Transformational planning, Tool Selection & Performance T...
Stork Webinar | APM Transformational planning, Tool Selection & Performance T...Stork
 
Uk-NO1 Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Exp...
Uk-NO1 Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Exp...Uk-NO1 Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Exp...
Uk-NO1 Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Exp...Amil baba
 
Robotics-Asimov's Laws, Mechanical Subsystems, Robot Kinematics, Robot Dynami...
Robotics-Asimov's Laws, Mechanical Subsystems, Robot Kinematics, Robot Dynami...Robotics-Asimov's Laws, Mechanical Subsystems, Robot Kinematics, Robot Dynami...
Robotics-Asimov's Laws, Mechanical Subsystems, Robot Kinematics, Robot Dynami...Sumanth A
 
1- Practice occupational health and safety procedures.pptx
1- Practice occupational health and safety procedures.pptx1- Practice occupational health and safety procedures.pptx
1- Practice occupational health and safety procedures.pptxMel Paras
 
Indian Tradition, Culture & Societies.pdf
Indian Tradition, Culture & Societies.pdfIndian Tradition, Culture & Societies.pdf
Indian Tradition, Culture & Societies.pdfalokitpathak01
 
Secure Key Crypto - Tech Paper JET Tech Labs
Secure Key Crypto - Tech Paper JET Tech LabsSecure Key Crypto - Tech Paper JET Tech Labs
Secure Key Crypto - Tech Paper JET Tech Labsamber724300
 
The Satellite applications in telecommunication
The Satellite applications in telecommunicationThe Satellite applications in telecommunication
The Satellite applications in telecommunicationnovrain7111
 
Novel 3D-Printed Soft Linear and Bending Actuators
Novel 3D-Printed Soft Linear and Bending ActuatorsNovel 3D-Printed Soft Linear and Bending Actuators
Novel 3D-Printed Soft Linear and Bending ActuatorsResearcher Researcher
 
March 2024 - Top 10 Read Articles in Artificial Intelligence and Applications...
March 2024 - Top 10 Read Articles in Artificial Intelligence and Applications...March 2024 - Top 10 Read Articles in Artificial Intelligence and Applications...
March 2024 - Top 10 Read Articles in Artificial Intelligence and Applications...gerogepatton
 
Analysis and Evaluation of Dal Lake Biomass for Conversion to Fuel/Green fert...
Analysis and Evaluation of Dal Lake Biomass for Conversion to Fuel/Green fert...Analysis and Evaluation of Dal Lake Biomass for Conversion to Fuel/Green fert...
Analysis and Evaluation of Dal Lake Biomass for Conversion to Fuel/Green fert...arifengg7
 
ADM100 Running Book for sap basis domain study
ADM100 Running Book for sap basis domain studyADM100 Running Book for sap basis domain study
ADM100 Running Book for sap basis domain studydhruvamdhruvil123
 
Structural Integrity Assessment Standards in Nigeria by Engr Nimot Muili
Structural Integrity Assessment Standards in Nigeria by Engr Nimot MuiliStructural Integrity Assessment Standards in Nigeria by Engr Nimot Muili
Structural Integrity Assessment Standards in Nigeria by Engr Nimot MuiliNimot Muili
 
Javier_Fernandez_CARS_workshop_presentation.pptx
Javier_Fernandez_CARS_workshop_presentation.pptxJavier_Fernandez_CARS_workshop_presentation.pptx
Javier_Fernandez_CARS_workshop_presentation.pptxJavier Fernández Muñoz
 
Comprehensive energy systems.pdf Comprehensive energy systems.pdf
Comprehensive energy systems.pdf Comprehensive energy systems.pdfComprehensive energy systems.pdf Comprehensive energy systems.pdf
Comprehensive energy systems.pdf Comprehensive energy systems.pdfalene1
 
Artificial Intelligence in Power System overview
Artificial Intelligence in Power System overviewArtificial Intelligence in Power System overview
Artificial Intelligence in Power System overviewsandhya757531
 
70 POWER PLANT IAE V2500 technical training
70 POWER PLANT IAE V2500 technical training70 POWER PLANT IAE V2500 technical training
70 POWER PLANT IAE V2500 technical trainingGladiatorsKasper
 

Dernier (20)

input buffering in lexical analysis in CD
input buffering in lexical analysis in CDinput buffering in lexical analysis in CD
input buffering in lexical analysis in CD
 
Triangulation survey (Basic Mine Surveying)_MI10412MI.pptx
Triangulation survey (Basic Mine Surveying)_MI10412MI.pptxTriangulation survey (Basic Mine Surveying)_MI10412MI.pptx
Triangulation survey (Basic Mine Surveying)_MI10412MI.pptx
 
Detection&Tracking - Thermal imaging object detection and tracking
Detection&Tracking - Thermal imaging object detection and trackingDetection&Tracking - Thermal imaging object detection and tracking
Detection&Tracking - Thermal imaging object detection and tracking
 
Livre Implementing_Six_Sigma_and_Lean_A_prac([Ron_Basu]_).pdf
Livre Implementing_Six_Sigma_and_Lean_A_prac([Ron_Basu]_).pdfLivre Implementing_Six_Sigma_and_Lean_A_prac([Ron_Basu]_).pdf
Livre Implementing_Six_Sigma_and_Lean_A_prac([Ron_Basu]_).pdf
 
Stork Webinar | APM Transformational planning, Tool Selection & Performance T...
Stork Webinar | APM Transformational planning, Tool Selection & Performance T...Stork Webinar | APM Transformational planning, Tool Selection & Performance T...
Stork Webinar | APM Transformational planning, Tool Selection & Performance T...
 
Uk-NO1 Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Exp...
Uk-NO1 Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Exp...Uk-NO1 Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Exp...
Uk-NO1 Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Exp...
 
Robotics-Asimov's Laws, Mechanical Subsystems, Robot Kinematics, Robot Dynami...
Robotics-Asimov's Laws, Mechanical Subsystems, Robot Kinematics, Robot Dynami...Robotics-Asimov's Laws, Mechanical Subsystems, Robot Kinematics, Robot Dynami...
Robotics-Asimov's Laws, Mechanical Subsystems, Robot Kinematics, Robot Dynami...
 
1- Practice occupational health and safety procedures.pptx
1- Practice occupational health and safety procedures.pptx1- Practice occupational health and safety procedures.pptx
1- Practice occupational health and safety procedures.pptx
 
Indian Tradition, Culture & Societies.pdf
Indian Tradition, Culture & Societies.pdfIndian Tradition, Culture & Societies.pdf
Indian Tradition, Culture & Societies.pdf
 
Secure Key Crypto - Tech Paper JET Tech Labs
Secure Key Crypto - Tech Paper JET Tech LabsSecure Key Crypto - Tech Paper JET Tech Labs
Secure Key Crypto - Tech Paper JET Tech Labs
 
The Satellite applications in telecommunication
The Satellite applications in telecommunicationThe Satellite applications in telecommunication
The Satellite applications in telecommunication
 
Novel 3D-Printed Soft Linear and Bending Actuators
Novel 3D-Printed Soft Linear and Bending ActuatorsNovel 3D-Printed Soft Linear and Bending Actuators
Novel 3D-Printed Soft Linear and Bending Actuators
 
March 2024 - Top 10 Read Articles in Artificial Intelligence and Applications...
March 2024 - Top 10 Read Articles in Artificial Intelligence and Applications...March 2024 - Top 10 Read Articles in Artificial Intelligence and Applications...
March 2024 - Top 10 Read Articles in Artificial Intelligence and Applications...
 
Analysis and Evaluation of Dal Lake Biomass for Conversion to Fuel/Green fert...
Analysis and Evaluation of Dal Lake Biomass for Conversion to Fuel/Green fert...Analysis and Evaluation of Dal Lake Biomass for Conversion to Fuel/Green fert...
Analysis and Evaluation of Dal Lake Biomass for Conversion to Fuel/Green fert...
 
ADM100 Running Book for sap basis domain study
ADM100 Running Book for sap basis domain studyADM100 Running Book for sap basis domain study
ADM100 Running Book for sap basis domain study
 
Structural Integrity Assessment Standards in Nigeria by Engr Nimot Muili
Structural Integrity Assessment Standards in Nigeria by Engr Nimot MuiliStructural Integrity Assessment Standards in Nigeria by Engr Nimot Muili
Structural Integrity Assessment Standards in Nigeria by Engr Nimot Muili
 
Javier_Fernandez_CARS_workshop_presentation.pptx
Javier_Fernandez_CARS_workshop_presentation.pptxJavier_Fernandez_CARS_workshop_presentation.pptx
Javier_Fernandez_CARS_workshop_presentation.pptx
 
Comprehensive energy systems.pdf Comprehensive energy systems.pdf
Comprehensive energy systems.pdf Comprehensive energy systems.pdfComprehensive energy systems.pdf Comprehensive energy systems.pdf
Comprehensive energy systems.pdf Comprehensive energy systems.pdf
 
Artificial Intelligence in Power System overview
Artificial Intelligence in Power System overviewArtificial Intelligence in Power System overview
Artificial Intelligence in Power System overview
 
70 POWER PLANT IAE V2500 technical training
70 POWER PLANT IAE V2500 technical training70 POWER PLANT IAE V2500 technical training
70 POWER PLANT IAE V2500 technical training
 

RSA SIGNATURE: BEHIND THE SCENES

  • 1. Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013 DOI : 10.5121/acij.2013.4203 27 RSA SIGNATURE: BEHIND THE SCENES Dragan Vidakovic1 , Dusko Parezanovic1 , Olivera Nikolic2 and Jelena Kaljevic2 1 Gimnazija Ivanjica, Serbia 2 Faculty of Business Valjevo, Singidunum University Belgrade, Serbia dragan.vidakovic@open.telekom.rs infomat@open.telekom.rs {onikolic,jkaljevic}@singidunum.ac.rs ABSTRACT In this paper, we present a complete digital signature message stream, just the way the RSA digital signature scheme does it. We will focus on the operations with large numbers due to the fact that operating with large numbers is the essence of RSA that cannot be understood by the usual illustrative examples with small numbers[1]. KEYWORDS Cryptography, Data Integrity, Digital Signature, Example 1. INTRODUCTION The idea of RSA is based on the belief that it is difficult to factor the number that is the product of two large prime numbers. Because of that it is necessary to develop the arithmetic of large numbers operations, as well as to encode the algorithm for number primality test, a hash function and many more auxiliary functions that are necessary for developing of the own digital signature software[4]. Many people have heard about a digital signature and read a notice saying that a document is digitally signed, but few of them have a real idea of what a digital signature is and how it looks like. Below, we will present in detail how to generate a digital signature. We are sure that this will be an inspiring step for many people to try to develop their own tools for the protection of their data integrity. 2. THE RSA SIGNATURE SCHEME In this paragraph, we will recall the steps that are necessary for the RSA scheme [2][3]. Algorithm Key generation for the RSA signature scheme SUMMARY: each entity creates an RSA public key and a corresponding private key.
  • 2. Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013 28 Each entity A should do the following: 1. Generate two large distinct random primes p and q, each roughly the same size (see x11.3.2). 2. Compute n = pq and = (p − 1)(q − 1). 3. Select a random integer e, 1 < e <  such that gcd(e, ) = 1. 4. Use the extended Euclidean algorithm ([2]) to compute the unique integer d, 1 < d < , such that ed ≡1 (mod ) 5. A’s public key is (n; e); A’s private key is d Algorithm RSA signature generation and verification SUMMARY: entity A signs a message m . Any entity B can verify A’s signature and recover the message m from the signature. 1. Signature generation. Entity A should do the following: (a) Compute m’ = R(m), an integer in the range [0; n − 1]. (b) Compute s = (m’)d mod n. (c) A’s signature for m is s. 2. Verification. To verify A’s signature s and recover the message m, B should: (a) Obtain A’s authentic public key (n; e). (b) Compute m’= se mod n. (c) Verify that m’ R; if not, reject the signature. (d) Recover m = R−1(m’). 3. PREPARATORY STEP In order to sign a message, we need to prepare many functions. Since Hash value of the message is central in the digital signature, we consider it is very important that we have a software for finding hash value. In this paragraph, we will show the algotithm and code for SHA-1. 3.1. SECURE HASH ALGORITHM (SHA-1) In this paragraph we specify SHA-1 [2], for several reasons: Because of the digital signature, to see how seem complicated and daunting and in the end because we can see how it can be solved by simply tools such as Delphi 7 console application. INPUT: bitstring x of bitlength b≥0. OUTPUT: 160-bit hash-code of x. 1. Definition of constans. Define a fifth (32-bit initial chaining values) IV to match those in MD4: h5 = 0xc3d2e1f0. h5 = 0xc3d2e1f0. Define per-round integer additive constants: y1 = 0x5a827999, y2 = 0x6ed9eba1, y3 = 0x8f1bbcdc, y4 = 0xca62c1d6. (No order for accessing source words, or specification of bit positions for left shifts is required.)
  • 3. Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013 29 2. Overall preprocessing. Pad as in MD4, except the final two 32-bit words specifying the bitlength b is appended with most significant word preceding least significant. As in MD4, the formatted input is 16m 32-bit words: x0x1 … x16m−1. Initialize chaining variables: (H1;H2;H3;H4;H5) ←(h1; h2; h3; h4; h5). 3. Processing. For each i from 0 to m − 1, copy the ith block of sixteen 32-bit words into temporary storage: X[j] ← x16i+j ; 0≤ j ≤ 15, and process these as below in four 20-step rounds before updating the chaining variables (expand 16-word block into 80-word block; let Xj denote X[j]) for j from 16 to 79, Xj  ((Xj-3(Xj-8 ⊕ Xj-14 ⊕ Xj-16)↵1). (initialize working variables) (A, B, C, D, E)  (H1, H2, H3, H4, H5). (Round 1) For j from 0 to 19 do the following: t ((A↵5) + f(B, C, D) + E + Xj + y1), (A, B, C, D, E)  (t, A, B↵30, C, D). (Round 2) For j from 20 to 39 do the following t ((A↵5) + h(B, C, D) + E + Xj + y2). (A, B, C, D, E) (t, A, B↵30, C, D). (Round 3) For j from 40 to 59 do the following: t ((A↵5) + g(B,C,D) + E + Xj + y3) (A, B, C, D, E)  (t, A, B↵30, C, D). (Round 4) For j from 60 to 79 do the following: t ((A↵5) + h(B, C, D) + E + Xj + y4). (A, B, C, D, E)  (t, A, B↵30, C, D). (update chaining values) (H1, H2, H3, H4, H5)  (H1 + A, H2 + B, H3 + C, H4 + D, H5 + E). 4. Completion. The hash-value is: H1 & H2 & H3 & H4 & H5. (with first and last bytes the high- and low-order bytes of H1, H5, respectively) Where: & : concatenation of strings + : addition modulo 232 f(u,v,w) = uv ∨ u’w g(u,v,w) = uv ∨ uw ∨ vw h(u,v,w) = u ⊕ v ⊕ w uv: and u’ : complement u ∨ v : or ⊕: exclusive or u ↵ s : rotation to the left for s position (X1, . . . , Xj) ← (Y1, . . . , Yj) : simultaneous assignment (Xi ← Yi).
  • 4. Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013 30 3.2. CODE FOR SHA-1 In this paragraph, we will encode upper algorithm. We will use console application Delphi 7. PROGRAM SHA_1; {$APPTYPE CONSOLE} var c1: char; k,i,j,l,duz,duz1,m,I1,I2,I3,I4:integer; a:array[1..8] of integer; a1,a2:array[1..32] of integer; h1,h2,h3,h4,h5,y1,y2,y3,y4,hh1,hh2,hh3,hh4,hh5,p:array [0..31] of integer; aa,bb,cc,dd,ee,pp,qq,rr,tt,ss,nn,mm:array[0..31] of integer; pom:array[0..35] of integer; x:array[0..79,0..31] of integer; f,g:file of integer; procedure dodeli(var a:array of integer;b:array of integer); var i:integer; begin for i:=0 to 31 do a[i]:=b[i]; end; procedure rot(var a:array of integer;t:integer); var i,k,l:integer; begin for i:=1 to t do begin k:=a[0]; for l:=0 to 30 do a[l]:=a[l+1]; a[31]:=k; end; end; procedure kom(var a:array of integer); var i,j:integer; begin for i:=0 to 31 do if a[i]=0 then a[i]:=1 else a[i]:=0; end; procedure fi(u,v,w:array of integer;var t:array of integer); var i,j:integer; p:array[0..31] of integer; begin for i:=0 to 31 do v[i]:=v[i] and u[i]; kom(u); for i:=0 to 31 do t[i]:=v[i] or (u[i] and w[i]); end; procedure gi(u,v,w:array of integer;var t:array of integer); var i,j:integer;
  • 5. Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013 31 begin for i:=0 to 31 do t[i]:=(u[i] and v[i]) or (u[i] and w[i]) or (v[i] and w[i]); end; procedure hi(u,v,w:array of integer;var t:array of integer); var i,j:integer; begin for i:=0 to 31 do t[i]:=(u[i] xor v[i]) xor w[i]; end; procedure saberi(a,b:array of integer;var w:array of integer); var c:integer; begin c:=0; for i:=31 downto 0 do begin w[i]:=(a[i]+b[i]+c) mod 2; if (a[i]+b[i]+c)<2 then c:=0 else c:=1; end; end; procedure ses(a,b,c,d:integer); var s:integer; begin s:=0; s:=a*8+b*4+c*2+d; if s=0 then write('0');if s=1 then write('1');if s=2 then write('2'); if s=3 then write('3');if s=4 then write('4');if s=5 then write('5'); if s=6 then write('6');if s=7 then write('7');if s=8 then write('8'); if s=9 then write('9');if s=10 then write('a');if s=11 then write('b'); if s=12 then write('c');if s=13 then write('d');if s=14 then write('e'); if s=15 then write('f'); end; begin writeln; writeln('Type your message to 147 symbols- because we use EOLN-Enter. For larger messages we can use files'); assign(g,'por.dat'); rewrite(g); duz:=0; writeln; write('Input message:'); while not eoln do begin read(c1); k:=ord(c1); for i:=1 to 8 do a[i]:=0; i:=1; while k<>0 do begin
  • 6. Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013 32 a[i]:=k mod 2; k:=k div 2; i:=i+1; end; duz:=duz+8; for I:=8 downto 1 do write(g,A[I]); end; {Padding} duz1:=duz; k:=1; l:=0; write(g,k); duz:=duz+1; if duz mod 512=0 then begin for i:=1 to 512-64 do write(g,l); duz:=duz+512-64; end else begin k:=duz mod 512; for i:=1 to 512-k-64 do write(g,l); duz:=duz+512-k-64; end; i:=1; while duz1<>0 do begin if i<=32 then begin a1[i]:=duz1 mod 2; duz1:=duz1 div 2 end else begin a2[i]:=duz1 mod 2; duz1:=duz1 div 2; end; i:=i+1; end; for i:=32 downto 1 do write(g,a2[i]); for i:=32 downto 1 do write(g,a1[i]); {big-endian } {end of pading} {Defining Constants} { Constants do not have to recalculate} h1[31]:=1;h1[30]:=0;h1[29]:=0;h1[28]:=0; h1[27]:=0;h1[26]:=0;h1[25]:=0;h1[24]:=0; h1[23]:=1;h1[22]:=1;h1[21]:=0;h1[20]:=0; h1[19]:=0;h1[18]:=1;h1[17]:=0;h1[16]:=0; h1[15]:=1;h1[14]:=0;h1[13]:=1;h1[12]:=0; h1[11]:=0;h1[10]:=0;h1[9]:=1;h1[8]:=0;
  • 7. Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013 33 h1[7]:=1;h1[6]:=1;h1[5]:=1;h1[4]:=0; h1[3]:=0;h1[2]:=1;h1[1]:=1;h1[0]:=0; h2[31]:=1;h2[30]:=0;h2[29]:=0;h2[28]:=1; h2[27]:=0;h2[26]:=0;h2[25]:=0;h2[24]:=1; h2[23]:=1;h2[22]:=1;h2[21]:=0;h2[20]:=1; h2[19]:=0;h2[18]:=1;h2[17]:=0;h2[16]:=1; h2[15]:=1;h2[14]:=0;h2[13]:=1;h2[12]:=1; h2[11]:=0;h2[10]:=0;h2[9]:=1;h2[8]:=1; h2[7]:=1;h2[6]:=1;h2[5]:=1;h2[4]:=1; h2[3]:=0;h2[2]:=1;h2[1]:=1;h2[0]:=1; h3[31]:=0;h3[30]:=1;h3[29]:=1;h3[28]:=1; h3[27]:=1;h3[26]:=1;h3[25]:=1;h3[24]:=1; h3[23]:=0;h3[22]:=0;h3[21]:=1;h3[20]:=1; h3[19]:=1;h3[18]:=0;h3[17]:=1;h3[16]:=1; h3[15]:=0;h3[14]:=1;h3[13]:=0;h3[12]:=1; h3[11]:=1;h3[10]:=1;h3[9]:=0;h3[8]:=1; h3[7]:=0;h3[6]:=0;h3[5]:=0;h3[4]:=1; h3[3]:=1;h3[2]:=0;h3[1]:=0;h3[0]:=1; h4[31]:=0;h4[30]:=1;h4[29]:=1;h4[28]:=0; h4[27]:=1;h4[26]:=1;h4[25]:=1;h4[24]:=0; h4[23]:=0;h4[22]:=0;h4[21]:=1;h4[20]:=0; h4[19]:=1;h4[18]:=0;h4[17]:=1;h4[16]:=0; h4[15]:=0;h4[14]:=1;h4[13]:=0;h4[12]:=0; h4[11]:=1;h4[10]:=1;h4[9]:=0;h4[8]:=0; h4[7]:=0;h4[6]:=0;h4[5]:=0;h4[4]:=0; h4[3]:=1;h4[2]:=0;h4[1]:=0;h4[0]:=0; h5[31]:=0;h5[30]:=0;h5[29]:=0;h5[28]:=0; h5[27]:=1;h5[26]:=1;h5[25]:=1;h5[24]:=1; h5[23]:=1;h5[22]:=0;h5[21]:=0;h5[20]:=0; h5[19]:=0;h5[18]:=1;h5[17]:=1;h5[16]:=1; h5[15]:=0;h5[14]:=1;h5[13]:=0;h5[12]:=0; h5[11]:=1;h5[10]:=0;h5[9]:=1;h5[8]:=1; h5[7]:=1;h5[6]:=1;h5[5]:=0;h5[4]:=0; h5[3]:=0;h5[2]:=0;h5[1]:=1;h5[0]:=1; y1[31]:=1;y1[30]:=0;y1[29]:=0;y1[28]:=1; y1[27]:=1;y1[26]:=0;y1[25]:=0;y1[24]:=1; y1[23]:=1;y1[22]:=0;y1[21]:=0;y1[20]:=1; y1[19]:=1;y1[18]:=1;y1[17]:=1;y1[16]:=0; y1[15]:=0;y1[14]:=1;y1[13]:=0;y1[12]:=0; y1[11]:=0;y1[10]:=0;y1[9]:=0;y1[8]:=1; y1[7]:=0;y1[6]:=1;y1[5]:=0;y1[4]:=1; y1[3]:=1;y1[2]:=0;y1[1]:=1;y1[0]:=0; y2[31]:=1;y2[30]:=0;y2[29]:=0;y2[28]:=0; y2[27]:=0;y2[26]:=1;y2[25]:=0;y2[24]:=1; y2[23]:=1;y2[22]:=1;y2[21]:=0;y2[20]:=1; y2[19]:=0;y2[18]:=1;y2[17]:=1;y2[16]:=1; y2[15]:=1;y2[14]:=0;y2[13]:=0;y2[12]:=1; y2[11]:=1;y2[10]:=0;y2[9]:=1;y2[8]:=1; y2[7]:=0;y2[6]:=1;y2[5]:=1;y2[4]:=1; y2[3]:=0;y2[2]:=1;y2[1]:=1;y2[0]:=0; y3[31]:=0;y3[30]:=0;y3[29]:=1;y3[28]:=1; y3[27]:=1;y3[26]:=0;y3[25]:=1;y3[24]:=1; y3[23]:=0;y3[22]:=0;y3[21]:=1;y3[20]:=1; y3[19]:=1;y3[18]:=1;y3[17]:=0;y3[16]:=1; y3[15]:=1;y3[14]:=1;y3[13]:=0;y3[12]:=1; y3[11]:=1;y3[10]:=0;y3[9]:=0;y3[8]:=0; y3[7]:=1;y3[6]:=1;y3[5]:=1;y3[4]:=1; y3[3]:=0;y3[2]:=0;y3[1]:=0;y3[0]:=1; y4[31]:=0;y4[30]:=1;y4[29]:=1;y4[28]:=0; y4[27]:=1;y4[26]:=0;y4[25]:=1;y4[24]:=1; y4[23]:=1;y4[22]:=0;y4[21]:=0;y4[20]:=0; y4[19]:=0;y4[18]:=0;y4[17]:=1;y4[16]:=1; y4[15]:=0;y4[14]:=1;y4[13]:=0;y4[12]:=0; y4[11]:=0;y4[10]:=1;y4[9]:=1;y4[8]:=0; y4[7]:=0;y4[6]:=1;y4[5]:=0;y4[4]:=1; y4[3]:=0;y4[2]:=0;y4[1]:=1;y4[0]:=1; dodeli(hh1,h1);dodeli(hh2,h2);dodeli(hh3,h3); dodeli(hh4,h4);dodeli(hh5,h5); m:=duz div 512; reset(g); {Processing} i:=0; while i<=m do
  • 8. Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013 34 begin for j:=0 to 15 do begin for l:=0 to 31 do read(g,x[j,l]); end; for j:=16 to 79 do begin for l:=0 to 31 do p[l]:=(((x[j-3,l] xor x[j-8,l]) xor x[j-14,l]) xor x[j-16,l]); l:=1; rot(p,l); for l:=0 to 31 do x[j,l]:=p[l]; end; i:=i+1; end; {initialize working variables} dodeli(aa,hh1);dodeli(bb,hh2);dodeli(cc,hh3); dodeli(dd,hh4);dodeli(ee,hh5); for j:=0 to 19 do begin dodeli(pp,aa); dodeli(ss,bb); dodeli(nn,cc); dodeli(mm,dd); for l:=0 to 31 do qq[l]:=x[j,l]; fi(bb,cc,dd,rr); rot(aa,5); saberi(aa,rr,pom); saberi(pom,ee,pom); saberi(pom,qq,pom); saberi(pom,y1,pom); for l:=0 to 31 do tt[l]:=pom[l]; dodeli(aa,tt);dodeli(bb,pp); rot(ss,30); dodeli(cc,ss); dodeli(dd,nn);dodeli(ee,mm); end; writeln; for j:=20 to 39 do begin dodeli(pp,aa);dodeli(ss,bb); dodeli(nn,cc); dodeli(mm,dd); for l:=0 to 31 do qq[l]:=x[j,l]; hi(bb,cc,dd,rr); rot(aa,5); saberi(aa,rr,pom); saberi(pom,ee,pom); saberi(pom,qq,pom); saberi(pom,y2,pom); for l:=0 to 31 do tt[l]:=pom[l];
  • 9. Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013 35 dodeli(aa,tt); dodeli(bb,pp);rot(ss,30);dodeli(cc,ss);dodeli(dd,nn); dodeli(ee,mm); end; for j:=40 to 59 do begin dodeli(pp,aa);dodeli(ss,bb); dodeli(nn,cc); dodeli(mm,dd); for l:=0 to 31 do qq[l]:=x[j,l]; gi(bb,cc,dd,rr); rot(aa,5); saberi(aa,rr,pom); saberi(pom,ee,pom); saberi(pom,qq,pom); saberi(pom,y3,pom); for l:=0 to 31 do tt[l]:=pom[l]; dodeli(aa,tt); dodeli(bb,pp);rot(ss,30);dodeli(cc,ss);dodeli(dd,nn); dodeli(ee,mm); end; for j:=60 to 79 do begin dodeli(pp,aa);dodeli(ss,bb); dodeli(nn,cc); dodeli(mm,dd); for l:=0 to 31 do qq[l]:=x[j,l]; hi(bb,cc,dd,rr); rot(aa,5); saberi(aa,rr,pom); saberi(pom,ee,pom); saberi(pom,qq,pom); saberi(pom,y4,pom); for l:=0 to 31 do tt[l]:=pom[l]; dodeli(aa,tt); dodeli(bb,pp);rot(ss,30);dodeli(cc,ss);dodeli(dd,nn); dodeli(ee,mm); end; saberi(hh1,aa,pom); for l:=0 to 31 do hh1[l]:=pom[l] ; saberi(hh2,bb,pom); for l:=0 to 31 do hh2[l]:=pom[l] ; saberi(hh3,cc,pom); for l:=0 to 31 do hh3[l]:=pom[l] ; saberi(hh4,dd,pom); for l:=0 to 31 do hh4[l]:=pom[l] ; saberi(hh5,ee,pom); for l:=0 to 31 do hh5[l]:=pom[l] ; writeln('Binary Hash value:'); writeln; for l:=0 to 31 do write(hh1[l]); for l:=0 to 31 do write(hh2[l]); for l:=0 to 31 do write(hh3[l]); for l:=0 to 31 do write(hh4[l]);
  • 10. Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013 36 for l:=0 to 31 do write(hh5[l]); writeln; assign(f,'hash.dat'); rewrite(f); writeln('hex hash value:'); writeln; for l:=31 downto 0 do write(f,hh5[l]); for l:=31 downto 0 do write(f,hh4[l]); for l:=31 downto 0 do write(f,hh3[l]); for l:=31 downto 0 do write(f,hh2[l]); for l:=31 downto 0 do write(f,hh1[l]); for l:=0 to 7 do begin i1:=hh1[4*l];i2:=hh1[4*l+1];i3:=hh1[4*l+2]; i4:=hh1[4*l+3]; ses(i1,i2,i3,i4); end; for l:=0 to 7 do begin i1:=hh2[4*l];i2:=hh2[4*l+1];i3:=hh2[4*l+2]; i4:=hh2[4*l+3]; ses(i1,i2,i3,i4); end; for l:=0 to 7 do begin i1:=hh3[4*l];i2:=hh3[4*l+1];i3:=hh3[4*l+2]; i4:=hh3[4*l+3]; ses(i1,i2,i3,i4); end; for l:=0 to 7 do begin i1:=hh4[4*l];i2:=hh4[4*l+1];i3:=hh4[4*l+2]; i4:=hh4[4*l+3]; ses(i1,i2,i3,i4); end; for l:=0 to 7 do begin i1:=hh5[4*l];i2:=hh5[4*l+1];i3:=hh5[4*l+2]; i4:=hh5[4*l+3]; ses(i1,i2,i3,i4); end; readln; readln; end. 3.3. EXAMPLES OF HASH VALUES The result of this function is the 160 series of zeros and ones whose order depends on the message. Examle 1: Using this software, we will determine the hash value of the message: Advanced Computing: An International Journal (ACIJ) Output to the screen: Input message:Advanced Computing: An International Journal (ACIJ)
  • 11. Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013 37 Binary Hash value: 101110111000000011110010011000000011110110000010010100111110010011110000110111 00 001101001111110101111010101001001101101001010001010001010010001101111001100001 01 hex hash value: bb80f2603d8253e4f0dc34fd7aa4da5145237985 Example 2. If we left out (:) in message: Advanced Computing: An International Journal (ACIJ) we get output to the screen: Input message:Advanced Computing An International Journal (ACIJ) Binary Hash value: 001000101000000011101010111001110111100110110111100001011101100000101111010000 00 010001110110000111011001001100011101110100010101000101001011000111000010100100 10 hex hash value: 2280eae779b785d82f404761d931dd1514b1c292 The omission of a single-letter hash value has undergone drastic changes. Undermined the integrity of the message. 4. HOW DIGITAL SIGNATURE LOOK IN REALITY In this paragraph, we will follow the steps of a message signing by the own software. It can be found in [4]. The first step of a scheme is to detect two large (probably) prime numbers p and q, of approximately the same number of digits. In this paper, we choose two 512-bit numbers that we got by using our software realization of the Miler-Rabin algorithm. Detected (probably) prime numbers are: p: 100000000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000010000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000100000
  • 12. Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013 38 000000000000000000000100000000000000000000000000000000000000000000000001000000 00000000000000000000000000000000010110011101 q: 100000000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000010000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000100000 000000000000000000000100000000000000000000000000000000000000000000000000000000 00000000000000000000000000000000011110000011 Using our software from [3], we compute n= p*q as well as  = (p-1)*(q-1) n=pq: 100000000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000100000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000001000000 000000000000000000001000000000000000000000000000000000000000000000000001000000 000000000000000000000000000000001101001000010000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000000000 000000000000001000000000000000000000000001000000000000000000000000000000000000 000000000000001000000000000000000000000000000000000001101001000001000000000000 000000000000010000000000000000000000000001000000000000000000000010000000000000 000000000000010000000000011010010000000000000000000011010010000000000000000000 000000000000000000000000011110000011000000000000000000000000000010101000101010 01010111. φ =(p-1)(q-1): 100000000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000100000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000001000000 000000000000000000001000000000000000000000000000000000000000000000000001000000 000000000000000000000000000000001101000111101000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000100000000000000000000000000100000000000000000000000000000000000 000000000000000100000000000000000000000000000000000000110100011110100000000000 000000000000001000000000000000000000000000100000000000000000000001000000000000 000000000000001000000000001101000111100000000000000001101000111100000000000000 000000000000000000000000001111000001000000000000000000000000000001010100001110 100111000. Then, we choose the public key, let’s assume e: 111, and using the same software we solve the equation e*d≡ 1 (mod φ), or cryptographically said, we compute the private key[4][6][7].
  • 13. Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013 39 d: 100100100100100100100100100100100100100100100100100100100100100100100100100100 100100100100100100100100100100100100100100100100100100100100100100100100100100 100100100100100100100100100100100100100100100100100100100100100100100100100100 100100100100100100101001001001001001001001001001001001001001001001001001001001 001001001001001001001001001001001001001001001001001001001001001001001010010010 010010010010010010011011011011011011011011011011011011011011011011011100100100 100100100100100100100100100100110011100100001001001001001001001001001001001001 001001001001001001001001001001001001001001001001001001001001001001001001001001 001001001001001101101101101101101101101110010010010010010010010010010010010010 010010010010010110110110110110110110110110110110110111110010110101001001001001 001001001001010010010010010010010010010010110110110110110110111000000000000000 000000000000001001001001011000001000100100100100100110011100100000000000000000 000000000000000000000000010001001010010010010010010010010010010011110010100010 111111. Let “Elektrotehnicki fakultet u Beogradu” be the message we should sign. Its hash value is: m: 00111111000111001010001001000111101110111010001100111111010000111100111110110001100001 1000110111010010010000100010100001001101110010010011100000101101000011011 The digital signature of a message m hash value is s= md mod n. s: 10111011000110000000011100010001100101111111010011100110101001100101000010111001010000 01100101101011101100011100001011111111100000100100011000001010001110111110000100100100 00011100001101000100011100011110000101101010100110100100111111000111000110000001110011 11010101010000111111001011011111110100011100110010110010011000110011100000010111100110 00010111100000101001011011100010000011000101000011000101100011011011100011011101101101 00111110010100001001011001110011001010010100100011010001000011111101011001110011010100 11011100001100111111101110100101110100010110101111101100001011100001010001010001011101 11000100110100011000110000110001010000100010110101011100010001001100010111011111011110 01000001000010111000001111011011000000001111100001110011110101110111111011111011000000 11111100010011010000100111111110111010101011110010110110011111111011110110111110110110 00011011001100111101100011101110110111100001011011000010000000111101010101000011010101 1001011100100001010101010100110011010111110110101101110111110110000110101001. If we check it, we get m’= se mod n. m’ : 00111111000111001010001001000111101110111010001100111111010000111100111110110001100001 10001101110100100100001000101000010011011100100100111000001011010000110110. By this, we are sure that using the previous operation, we really get the same value (m=m’). it means that the data integrity is preserved and that the owner of a private key is the one who signed the message.
  • 14. Advanced Computing: An International Journal ( ACIJ ), Vol.4, No.2, March 2013 40 5. FUTURE WORK In the arguments for and against in a trial of strength of ECC (Elliptic Curve Cryptography) and RSA, the simple fact that they are performed by the same tools made for operations with large numbers, is usually overlooked. Mathematical bases of RSA and ECC are completely different [2] [8], but they need the same operations: addition, subtraction, multiplication, division, finding the remainder, calculating d from the equation e*d ≡ 1 (mod p) for fixed values of e and p, SHA-1 and more other joint auxiliary operations needed for the realization of a digital signature in both schemes. Therefore, ECC is our next goal-because we have the tools. 6. CONCLUSION We believe that each country must stimulate young people’s interest in cryptography, because we doubt that our secret data can be protected using someone else’s software. Of course, it is very difficult to develop our own protection mechanisms, but we think it is far better to protect data using our own mechanisms first, and then, thus modified, leave them to someone else’s software, than to allow the original data be protected by somebody else’s mechanisms, which is a logical nonsense. That is the reason why we always insist on more our own softwares and a greater interest in cryptography, which seems itself (in case it wasn’t brought closer to a reader) pretty cryptic and bouncing[5]. So, this work is primarily addressed to young researches as an incentive to try to develop their own tools for data protection. Those tools do not have to be flawless, they may be far below the level of the tools found on the market. However, they should be good enough for the beginning of a hard work that would lead researches to some great commercial solutions. REFERENCES [1] D.Vidakovic, O. Nikolic, D. Parezanovic, “Acceleration Detection of Large (Probably) Prime Numbers”, International Journal of UbiComp (IJU), Vol.4, No.1, January 2013 [2] A. Menezes, P.C. van Oorschot, S. Vanstone, Handbook of Applied Cryptography, CRC Press, New York, 1997. [3] B. Schneier, Applied Cryptography, John Wiley & Sons, New York, 1996. [4] D. Vidaković, “Analysis and implementation of asymmetric algorithms for data secrecy and integrity protection”, Master Thesis (mentor Jovan Golic), Faculty of Electrical Engineering, Belgrade 1999. [5] D. Vidakovic, D. Simic, “A Novel Approach To Building Secure Systems“, ARES 2007, Vienna, Austria, pp 1074-1084. [6] C. Zhang, “An improved binary algorithm for RSA”, Computers and Mathematics with Applications, 25:6 (1993), 15–24. [7] S.-M. Hong, S.-Y. OH, and H. Yoon, “New modular multiplication algorithms for fast modular exponentiation”, Advances in Cryptology–EUROCRYPT ’96 (LNCS 1070), 166–177, 1996 [8] N. Koblitz, “Elliptic Curve Cryptosystems”, Mathematics of Computations, 48, pp. 203-209, 1987.