Stream Cipher Topics



Download 0,67 Mb.
bet4/4
Sana01.03.2022
Hajmi0,67 Mb.
#476860
1   2   3   4
Bog'liq
Stream Cipher

The PRGA

  • Generate key stream k , one by one
  • XOR S[k] with next byte of message to encrypt/decrypt
    • i = j = 0;
    • While (more_byte_to_encrypt)
      • i = (i + 1) (mod 256);
      • j = (j + S[i]) (mod 256);
      • swap(S[i], S[j]);
      • k = (S[i] + S[j]) (mod 256);
      • Ci = Mi XOR S[k];
  • Sum of shuffled pair selects "stream key" value from permutation

RC4 Lookup Stage

  • The output byte is selected by looking up the values of S[i] and S[j], adding them together modulo 256, and then looking up the sum in S
  • S [S[i] + S[j]] is used as a byte of the key stream, K
  • http://en.wikipedia.org/wiki/File:RC4.svg
    • i = j = 0;
    • While (more_byte_to_encrypt)
      • i = (i + 1) (mod 256);
      • j = (j + S[i]) (mod 256);
      • swap(S[i], S[j]);
      • k = (S[i] + S[j]) (mod 256);
      • Ci = Mi XOR S[k];

Detailed Diagram

Overall Operation of RC4

Decryption using RC4

  • Use the same secret key as during the encryption phase.
  • Generate keystream by running the KSA and PRGA.
  • XOR keystream with the encrypted text to generate the plain text.
  • Logic is simple :
  • (A xor B) xor B = A A = Plain Text or Data B = KeyStream

Download 0,67 Mb.

Do'stlaringiz bilan baham:
1   2   3   4




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©hozir.org 2024
ma'muriyatiga murojaat qiling

kiriting | ro'yxatdan o'tish
    Bosh sahifa
юртда тантана
Боғда битган
Бугун юртда
Эшитганлар жилманглар
Эшитмадим деманглар
битган бодомлар
Yangiariq tumani
qitish marakazi
Raqamli texnologiyalar
ilishida muhokamadan
tasdiqqa tavsiya
tavsiya etilgan
iqtisodiyot kafedrasi
steiermarkischen landesregierung
asarlaringizni yuboring
o'zingizning asarlaringizni
Iltimos faqat
faqat o'zingizning
steierm rkischen
landesregierung fachabteilung
rkischen landesregierung
hamshira loyihasi
loyihasi mavsum
faolyatining oqibatlari
asosiy adabiyotlar
fakulteti ahborot
ahborot havfsizligi
havfsizligi kafedrasi
fanidan bo’yicha
fakulteti iqtisodiyot
boshqaruv fakulteti
chiqarishda boshqaruv
ishlab chiqarishda
iqtisodiyot fakultet
multiservis tarmoqlari
fanidan asosiy
Uzbek fanidan
mavzulari potok
asosidagi multiservis
'aliyyil a'ziym
billahil 'aliyyil
illaa billahil
quvvata illaa
falah' deganida
Kompyuter savodxonligi
bo’yicha mustaqil
'alal falah'
Hayya 'alal
'alas soloh
Hayya 'alas
mavsum boyicha


yuklab olish