Вы находитесь на странице: 1из 29

Q4(a)

Bit Position

KEY- 2223 4512 987A BB23

1
0
17
0
33
1
49
1

2
0
18
1
34
0
50
0

3
1
19
0
35
0
51
1

4
0
20
0
36
1
52
1

5
0
21
0
37
1
53
1

6
0
22
1
38
0
54
0

7
1
23
0
39
0
55
1

8
0
24
1
40
0
56
1

9
0
25
0
41
0
57
0

10
0
26
0
42
1
58
0

11
1
27
0
43
1
59
1

12
0
28
1
44
1
60
0

13
0
29
0
45
1
61
0

14
0
30
0
46
0
62
0

15
1
31
1
47
1
63
1

16
1
32
0
48
0
64
1

PC-1
57
0

49
1

41
0

33
1

25
0

17
0

9
0

58

50

42

34

26

18

10

59

51

43

35

27

19

11

60

52

44

36

63

55

47

39

31

23

15

62

54

46

38

30

22

14
0

6
0

61
0

53
1

45
1

37
1

29
0

21

13

28

20

12

56Bit-KEY After PC-1

Left 28bit key

Right 28bit Key

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

ROUND 1
56bit key After PC-1

Left 28bit key

Right 28bit key

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

56Bit-KEY After Round 1 Left Circular Shift(1 Bit shift)

Left 28bit key

Right 28bit key

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

PC-2
14
0
15
0
26
1
41
1
51
0
34
1

17
1
6
0
8
0
52
1
45
1
53
0

11
0
21
0
16
1
31
0
33
0
46
1

24
0
10
1
7
0
37
0
48
0
42
0

1
1
23
1
27
1
47
1
44
0
50
0

5
0
19
0
20
0
55
0
49
0
36
0

3
1
12
0
13
1
30
1
39
0
29
1

28
0
4
0
2
0
40
0
56
1
32
1

Bit Position

48 Bit-KEY round 1 subkey K1


1

10 11 12 13 14 15 16 17 18 19 20 21 22 23 24

25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
1

Subkey K1 - 4A18AA CA41A3

ROUND 2
56Bit-KEY After Round 1 Left Circular Shift(LCS)

Left 28bit key

Right 28bit key

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

56Bit-KEY After Round 2 LCS(1 Bit shift)

Left 28bit key

Right 28bit key

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

PC-2
14
0
15
1
26
1
41
0
51
1
34
1

17
1
6
0
8
0
52
0
45
1
53
0

11
0
21
1
16
1
31
1
33
1
46
1

24
1
10
0
7
0
37
0
48
0
42
0

1
0
23
0
27
0
47
0
44
1
50
0

5
0
19
0
20
0
55
1
49
0
36
0

3
0
12
1
13
0
30
0
39
0
29
1

28
1
4
0
2
1
40
1
56
1
32
0

Bit Position

SubKey K2 of Round 2
1

10 11 12 13 14 15 16 17 18 19 20 21 22 23 24

25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
0

Subkey K2:- 51A2A1 25E9A2

ROUND 3
56Bit-KEY After Round 2 LCS(1 Bit shift)

Left 28bit key

Right 28bit key

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

56Bit-KEY After Round 3 LCS(2 bit shift)

Left 28bit key

Right 28bit key

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

PC-2
14
1
15
1
26
1
41
0
51
0
34
0

17
0
6
0
8
0
52
0
45
0
53
1

11
0
21
0
16
0
31
1
33
0
46
0

24
1
10
1
7
1
37
0
48
0
42
1

1
0
23
1
27
0
47
0
44
1
50
0

5
0
19
1
20
1
55
1
49
1
36
0

3
0
12
0
13
1
30
0
39
0
29
1

28
1
4
0
2
0
40
0
56
0
32
1

Bit Position

SubKey K3 of Round 3
1

10 11 12 13 14 15 16 17 18 19 20 21 22 23 24

25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
0

Subkey K3:- 919C96 240C53

Round 4
56Bit-KEY After Round 3 LCS(2 bit shift)

Left 28bit key

Right 28bit key

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

56Bit-KEY After Round 4 LCS(2 bit shift)

Left 28bit key

Right 28bit key

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

PC-2
14
0
15
0
26
1
41
1
51
1
34
0

17
1
6
0
8
1
52
1
45
0
53
1

11
1
21
1
16
0
31
0
33
0
46
0

24
1
10
0
7
0
37
0
48
0
42
1

1
0
23
0
27
0
47
1
44
0
50
0

5
1
19
0
20
1
55
1
49
0
36
1

3
0
12
1
13
1
30
1
39
0
29
1

28
0
4
0
2
0
40
1
56
0
32
0

Bit Position

SubKey K4 of Round 4
1

10 11 12 13 14 15 16 17 18 19 20 21 22 23 24

25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
1

Subkey K4:- 7422C6 CF8056

Round 5
56Bit-KEY After Round 4 LCS(2 bit shift)

Left 28bit key

Right 28bit key

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

56Bit-KEY After Round 5 LCS(2 bit shift)

Left 28bit key

Right 28bit key

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

PC-2
14
0
15
1
26
0
41
0
51
1
34
1

17
0
6
1
8
0
52
0
45
1
53
1

11
1
21
0
16
1
31
0
33
0
46
0

24
1
10
1
7
0
37
0
48
0
42
0

1
0
23
0
27
0
47
0
44
0
50
1

5
0
19
1
20
1
55
1
49
1
36
0

3
1
12
0
13
0
30
0
39
1
29
0

28
0
4
0
2
0
40
1
56
1
32
0

Bit Position

SubKey K5 of Round 5
1

10 11 12 13 14 15 16 17 18 19 20 21 22 23 24

25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
0

Subkey K5:- 32DC24 05C7C8

Round 6
56Bit-KEY After Round 5 LCS(2 bit shift)

Left 28bit key

Right 28bit key

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

56Bit-KEY After Round 6 LCS(2 bit shift)

Left 28bit key

Right 28bit key

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

PC-2
14
1
15
0
26
0
41
0
51
1
34
0

17
1
6
0
8
1
52
0
45
0
53
1

11
0
21
0
16
1
31
0
33
0
46
0

24
0
10
0
7
1
37
1
48
1
42
0

1
1
23
0
27
0
47
1
44
0
50
0

5
0
19
0
20
1
55
0
49
1
36
1

3
0
12
0
13
1
30
0
39
0
29
0

28
0
4
1
2
0
40
0
56
0
32
1

Bit Position

SubKey K6 of Round 6
1

10 11 12 13 14 15 16 17 18 19 20 21 22 23 24

25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
0

Subkey K6:- C80176 189445

Round 7
56Bit-KEY After Round 6 LCS(2 bit shift)

Left 28bit key

Right 28bit key

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

56Bit-KEY After Round 7 LCS(2 bit shift)

Left 28bit key

Right 28bit key

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

PC-2
14
1
15
1
26
0
41
1
51
1
34
1

17
0
6
1
8
0
52
1
45
1
53
0

11
1
21
0
16
1
31
0
33
0
46
1

24
0
10
0
7
1
37
0
48
0
42
0

1
0
23
0
27
1
47
1
44
0
50
0

5
1
19
0
20
1
55
0
49
1
36
1

3
0
12
1
13
0
30
1
39
0
29
0

28
0
4
0
2
1
40
0
56
0
32
0

Bit Position

SubKey K7 of Round 7:1

10 11 12 13 14 15 16 17 18 19 20 21 22 23 24

25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
1

Subkey K7:- A4C23D CAC4A4

Round 8
56Bit-KEY After Round 7 LCS(2 bit shift)

Left 28bit key

Right 28bit key

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

56Bit-KEY After Round 8 LCS(2 bit shift)

Left 28bit key

Right 28bit key

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

Bit Position

PC-2
14
1
15
0
26
0
41
0
51
0
34
1

17
0
6
0
8
0
52
0
45
1
53
0

11
0
21
0
16
1
31
0
33
1
46
0

24
0
10
1
7
0
37
0
48
0
42
0

1
0
23
0
27
0
47
1
44
1
50
1

5
1
19
0
20
0
55
0
49
1
36
0

3
1
12
1
13
1
30
0
39
1
29
0

28
1
4
1
2
0
40
0
56
1
32
1

Bit Position

SubKey K8 of Round 8
1

10 11 12 13 14 15 16 17 18 19 20 21 22 23 24

25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
0

Subkey K8:- 871322 086F89

Q4(b)
Bit Position

Plain Text 0000000000000001


Plain Text in 64bit
1
0
17
0
33
0
49
0

2
0
18
0
34
0
50
0

3
0
19
0
35
0
51
0

4
0
20
0
36
0
52
0

6
0
22
0
38
0
54
0

7
0
23
0
39
0
55
0

8
0
24
0
40
0
56
0

9
0
25
0
41
0
57
0

10
0
26
0
42
0
58
0

11
0
27
0
43
0
59
0

12
0
28
0
44
0
60
0

13
0
29
0
45
0
61
0

14
0
30
0
46
0
62
0

15
0
31
0
47
0
63
0

16
0
32
0
48
0
64
1

Bit Position

IP
58
0
60
0
62
0
64
1
57
0
59
0
61
0
63
0

5
0
21
0
37
0
53
0

50
0
52
0
54
0
56
0
49
0
51
0
53
0
55
0

42
0
44
0
46
0
48
0
41
0
43
0
45
0
47
0

34
0
36
0
38
0
40
0
33
0
35
0
37
0
39
0

26
0
28
0
30
0
32
0
25
0
27
0
29
0
31
0

18
0
20
0
22
0
24
0
17
0
19
0
21
0
23
0

10
0
12
0
14
0
16
0
9
0
11
0
13
0
15
0

64Bit Text After IP

2
0
4
0
6
0
8
0
1
0
3
0
5
0
7
0

Left 32bit

Right 32bit

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

Expansion of
32
0
4
0
8
0
12
0
16
0
20
0
24
0
28
0

Right 32-bit

1
0
5
0
9
0
13
0
17
0
21
0
25
0
29
0

2
0
6
0
10
0
14
0
18
0
22
0
26
0
30
0

3
0
7
0
11
0
15
0
19
0
23
0
27
0
31
0

After Expansion Table

4
0
8
0
12
0
16
0
20
0
24
0
28
0
32
0

Right 48bit

5
0
9
0
13
0
17
0
21
0
25
0
29
0
1
0

Bit Position

Bit Position

(R48)

10 11 12 13 14 15 16 17 18 19 20 21 22 23 24

25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
0

Bit Position

Round 1 48bit subkey K1 (K1)


1

10 11 12 13 14 15 16 17 18 19 20 21 22 23 24

25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
1

After R48

XOR K1

Bit Position

10 11 12 13 14 15 16 17 18 19 20 21 22 23 24

25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
1

Tables of 8 S-Boxes

Fig 4(b).1 Definition of DES S-Boxes

S-Box

6bit(i/p)

S1
S2
S3
S4
S5
S6
S7
S8

Row
No(b=d)
00=0
11=3
10=2
10=2
10=2
10=2
00=0
11=3

010010
100001
100010
101010
110010
100100
000110
100011

After Substitution

Col No(b=d) Table Value 4bit(o/p)


1001=9
0000=0
0001=1
0101=5
1001=9
0010=2
0011=3
0001=1

10
13
6
11
9
15
14
1

1010
1101
0110
1011
1001
1111
1110
0001

Right 32bit

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

Permutation (PR)
16
1
1
1
2
0
19
0

7
0
15
1
8
1
13
1

20
1
23
1
24
1
30
0

Bit Position

21
1
26
1
14
0
6
1

RP

29
0
5
1
32
1
22
1

12
0
18
0
27
1
11
1

28
0
31
0
3
1
4
0

17
1
10
1
9
0
25
1

Right 32bit

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

L0

Left 32bit

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

After RP

XOR L0

Right 32bit

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

After ROUND 1.
L1

Left 32bit

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

L1 :- 00000000
R1

Right 32bit

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

R1 :- B1F96EDD

Q1
Q1 a)
1) The main advantage of compressing any data is it reduces redundancy. That
is, the repetition of data or characters. Thus the frequency of occurrence of
a character in message is reduced on compression.
2) On encryption of compressed message, the crypt analysis will be difficult.
3) Moreover, the brute force attack will take longer. Since, it depends on the
frequency of occurrences of characters in message using various random
keys and check whether the output makes sense. On compression, the
attacker first has to decrypt using random keys and then decompress it.

Q1 b)
Keyword:-

SOUMYA
S
Y
D
H
L
T

PlainText:- I LOVE

O
A
E
I
N
V

CRYPTOGRAPHY

I L -> H N
O V -> A O
E C -> G A
R Y -> L C
P T -> L W
O G -> M E
R A -> N C
P H -> L J
Y P -> B L
Cipher Text:- HNAPGALCLWMENCLJBL

U
B
F
J
P
W

M
C
G
K
R
Z

Q1 c) Plain Text:- I STUDY IN LOVELY PROFESSIONAL UNIVERSITY


Key:- MR BALACHANDRAN IS MY FATHER MRS BEENA IS MY
S.No
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36

PLAIN VALUE
TEXT (vp )

KEY

I
S
T
U
D
Y
I
N
L
O
V
E
L
Y
P
R
O
F
E
S
S
I
O
N
A
L
U
N
I
V
E
R
S
I
T
Y

M
R
B
A
L
A
C
H
A
N
D
R
A
N
I
S
M
Y
F
A
T
H
E
R
M
R
S
B
E
E
N
A
I
S
M
Y

08
18
19
20
03
24
08
13
11
14
21
04
11
24
15
17
14
05
04
18
18
08
14
13
00
11
20
13
08
21
04
17
18
08
19
24

VALU
E (vK)
12
17
01
00
11
00
02
07
00
13
03
17
00
13
08
18
12
24
05
00
19
07
04
17
12
17
18
01
04
04
13
00
08
18
12
24

Vp + Vk
(mod25)
20
10
20
20
14
24
10
20
11
2
24
21
11
12
23
10
1
4
9
18
12
15
18
5
12
3
13
14
12
0
17
17
1
1
6
23

CIPHER
TEXT
U
K
U
U
O
Y
K
U
L
C
Y
V
L
M
X
K
B
E
J
S
M
P
S
F
M
D
N
O
M
A
R
R
B
B
G
X

Cipher Text:

UKUUOYKULCYVLMXKBEJSMPSFMDNOMARRBBGX

Two difficulties faced by the ONE-TIME Pad are the following.


1) In this, a system must have a large quantity of random characters to
generate key. In the above example for a plain text of length 36, the system
had to provide key of same length. Thus for a system that are used heavily,
have a significant responsibility to generate random characters in big
volume.
2) In this, for every message to be sent, sender and receiver must need a new
key of equal length of the message. Thus, its difficult to ensure key
distribution and protection. But its tough to ensure this for such a long
length of message.

Q1 d)
PLAIN TEXT: - MY BIRTH MONTH IS JANUARY AND I WAS BORN IN

KATTANAM.
Single transposition:

KEY->

4
M
M
J
A
B
A

3
Y
O
A
N
O
T

1
B
N
N
D
R
T

2
I
T
U
I
N
A

5
R
H
A
W
I
N

6
T
I
R
A
N
A

7
H
S
Y
S
K
M

Cipher Text:

BNNDRTITUINAYOANOTMMJABARHAWINTIRANAHSYSKM

Double transposition
Text:- BNNDRTITUINAYOANOTMMJABARHAWINTIRANAHSYSKM

Key->

4
B
T
A
A
I
A

3
N
U
N
B
N
H

1
N
I
O
A
T
S

2
D
N
T
R
I
Y

5
R
A
M
H
R
S

6
T
Y
M
A
A
K

7
I
O
J
W
N
M

Final Cipher Text :-

NIOATSDNTRIYNUNBNHBTAAIARAMHRSTYMAAKIOJWNM
Q1 e)
We assume that

Plain Text :- MY NAME IS SOUMYA BALACHANDRAN NAIR


1

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

STREAM CIPHER
For stream cipher, we take whole plain text to encrypt bit by bit.
Thus,
STREAM Text will be
1

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

For encryption,
We use RAIL FENCE technique

M A
Y

Cipher text of stream will be

MAIOYACNAAYMSUALHDNINESMBAARNR
BLOCK CIPHER
In Block Cipher ,we split plain text into two parts of equal size,
Left Half
1
M

2
Y

3
N

4
A

5
M

6
E

7
I

8
S

9
S

10
O

11
U

12
M

13
Y

14
A

15
B

3
A

4
C

5
H

6
A

7
N

8
D

9
R

10
A

11
N

12
N

13
A

14
I

15
R

Right Half
1
A

2
L

Then we perform RAIL FENCE technique on each and then the resultant cipher will
be combined together to generate final cipher text.
RAIL FENCE on Left Half

Cipher(L)

MAIOYYMSUANESMB

RAIL FENCE on Right Half

Cipher(R)

ACNAALHDNIAARNR
FINAL CIPHER TEXT ON BLOCK CIPHER IS

Cipher Text = Cipher(L) + Cipher(R)

MAIOYYMSUANESMBACNAALHDNIAARNR
Note:- On both stream cipher and block cipher, only the first and last five bits of cipher text are same.

Q2
a) A students breaks into a professors office to obtain a copy of
the next days test.
Ans) It will be Release of Message Content under PASSIVE ATTACK
because the student is copying the test paper but is not altering
anything on the original.
Passive Attack: - Nature of eavesdropping on, or monitoring of,
transmission.
b) A student gives a cheque for $10 to buy a used book. Later she
finds the cheque was cashed for $100.
Ans) It will be Modification of Message under ACTIVE ATTACK
because the original check was altered without any knowledge of the
student.

Modification of Message :- Some portion of a legitimate message is


altered
Active Attack :- Some modification of the data stream or the creation
of a false stream.
c) A student sends hundred of e-mails per day to another student
using a phony return e-mail address.
Ans) It will be Masquerade under Active Attack because student is
sending a false return e-mail address so that the receiver wont know
who the sender is.
Masquerade:- When one entity pretends to be a different entities.
d) A student is trying to break an encrypted text by randomly
choosing values as keys.
Ans) It will be Brute Force Attack because the student is randomly
choosing key values.
Brute Force Attack :- The attacker tries every possible keys on cipher
text to translate until intelligible plain text is obtained.
e) A student is listening to the conversation being held in the class
between another student and the teacher.
Ans) It will be Passive Attack because student only listening to
conversation but not altering the message.

Q 3 a)
Cipher
D
E
L
W
CDE = [3

4]

CLW = [11

12]

KEY = [11

8]

[3

Value
3
4
11
22

7]

del (K) = (77 - 24) = 53


K-1 = (1/del(k)) * [7

-8] * mod 26

[-3
= (1/53) * [7
[-3

11]

-8] * mod 26
11]

Now, (1/53)mod 26 => 53 * x = 1 mod 26


X=1
Therefore, (1/53)mod 26 = 1
K-1 = [7
[-3
K-1 = [7
[23

-8] mod 26
11]
18]
11]

Decryption of DE = CDE K-1 mod 26


= [3

4] [7

18] mod 26

[23 11]
= [9

20]

= [J

U]

Decryption of LW = CLW K-1 mod 26


= [11 22] [7

18] mod 26

[23 11]
= [583

440] mod 26

= [11 24]
= [L

Y]

Hence, Plain text after the decryption of DELW is JULY

Q3 b) Cipher Text is
YIFQFMZRWQFYVECFMDZPCVMRZWNMDZVEJBTXCDDUMJ
NDIFEFMDZCDMQZKCEYFCJMYRNCWJCSZREXCHZUNMXZ
NZUCDRJXYYSMRTMEYIFZWDYVZVYFZUMRZCRWNZDZJJ
XZWGCHSMRNMDHNCMFQCHZJMXJZWIEJYUCFWDJNZDIR
Frequency of occurrences of alphabets in cipher text is
Z=21
R=10

M=16
N=10

C=15
W=8

D=13
E=7

J=11
X=6

Y=10
V=5

F=10
U=5

I=5
K=1

H=4
G=1

Q=4

S=3

T=2

P=1

B=1

Fig 3(b).1: Relative frequency of letters in English text.

From the figure 3(b).1, the frequency of E is highest in English text. Therefore, we
assume Z(Highest frequency) in cipher text is E

FMD occurs 4 times => FID


ZW Occurs 3 times => EW
MR Occurs 4 times => IR
ZR

Occurs 2 times => ER

From FMD and MR we assume M is I as I is vowel and has next highest frequency.
Then C has next higher frequency. So we assume C is A.

YIFQFMZRWQFYVECFMD
Comparing

ZRW

and

ER , we assume that W is D.

On comparing D and J in cipher text and the higher frequency occurrence in


English Text, its coming D as S and J as T
Replacing Y as O and F as R

FMD=>RIS
Cipher Text

Y I
O
V M
I
N D
S
M Y
I O
N Z
E
D Y
S O
X Z
E
J M
T I

F
R
R

Q F
R
Z W
E D
I F E
R
R N C
A
U C D
A S
V Z V
E
W G C
D
A
X J Z
T E

M Z
I E
N M
I
F M
R I
W J
D T
R J
T
Y F
O R
H S
W I
D

R
D
S
D
S
C
A
X

W
D
Z
E
Z
E
S

Q F
R
V E

C
A
Z
E
Y Y
O O
Z U M
E
I
M R N
I
E J Y
T

D
S
R
S

Decrypted text.

Y
O
J
T
M
I
E

M
I
R Z
E
M D
I S
U C
A

V E
B
Q
X
R
C
A
H
F

C
A
X

F
R
T
C
A
Z K C
E
A
C H Z
A
E
T M E
I
R W N
D
N C M
A I
W D J
D
T

M
I
D
S
E

D
S
D
S
Y
O
U N
Y
O
Z
E
F
R
N

I
D
S
Q
Z
E

Z P
E
U M
I
F C
R A
M X
I
F Z
R E
Z J
E T
C H
A
D I
S

C
A
J
T
J
T
Z
E
W
D
J
T
Z
E
R

From above, we can guess that first sentence may be OUR FRIEND FROM PARIS,
thus I will be U, Q will be F, V will be M and E will be

P.

Y
O
V
M
N

I
U
M
I
D
S
M Y
I O
N Z
E
D Y
S O
X Z
E
J M
T I

F
R
R
N
I
U
R
N
U

Q
F
Z
E
F
R
N

C
A
V Z
M E
W G
D
X J
T

F
R
W
D
E
P
C
A
D
S
V
M
C
A
Z
E

M Z
I E
N M
I
F M
R I
W J
D T
R J
N T
Y F
O R
H S

R
N
D
S
D
S
C
A
X

W
D
Z
E
Z
E
S

Q
F
V
M
C
A
Z
E
Y Y
O O
Z U M
E
I
M R N
I N
W I E J Y
D U P T O

F
R
E
P
D
S
R
N
S

Y
O
J
T
M
I
E
P
M
I
R Z
N E
M D
I S
U C
A

V E
M P
B T

C
A
X

F
R
C
A
Q Z K C
F E
A
X C H Z
A
E
R T M E
N
I P
C R W N
A N D
H N C M
A I
F W D J
R D S T

M
I
D
S
E
P
U

D
S
D
S
Y
O
N

Y
O
Z
E
F
R
N

I
U
D
S
Q
F
Z
E

Z P
E
U M
I
F C
R A
M X
I
F Z
R E
Z J
E T
C H
A
D I
S U

C
A
J
T
J
T
Z
E
W
D
J
T
Z
E
R
N

From above, we can guess that N will be H,K will be V, P will be X, S will be K
and X will be L,
Thus,
Y
O
V
M
N
H
M
I
N
H
D
S
X
L
J
T

I
U
M
I
D
S
Y
O
Z
E
Y
O
Z
E
M
I

F
R
R
N
I
U
R
N
U

Q
F
Z
E
F
R
N
H
C
A
V Z
M E
W G
D
X J
L T

F
R
W
D
E
P
C
A
D
S
V
M
C
A
Z
E

M
I
N
H
F
R
W
D
R
N
Y
O
H

Z
E
M
I
M
I
J
T
J
T
F
R
S
K
W I
D U

R
N
D
S
D
S
C
A
X
L
Z
E
M
I
E
P

W
D
Z
E
Z
E
S
K
Y
O
U
R
N
J
T

Q
F
V
M
C
A
Z
E
Y
O
M
I
N
H
Y
O

F
R
E
P
D
S
R
N
S
K
R
N
M
I
U

Y
O
J
T
M
I
E
P
M
I
Z
E
D
S
C
A

V E
M P
B T

C
A
X
L
K
V
H

F
R
C
A
Q Z
C
F E
A
X C
Z
L A
E
R T M E
N
I P
C R W N
A N D H
H N C M
H A I
F W D J
R D S T

M
I
D
S
E
P
U

D
S
D
S
Y
O
N
H
Y I
O U
Z D
E S
F Q
R F
N Z
H E

Z P
E X
U M
I
F C
R A
M X
I L
F Z
R E
Z J
E T
C H
A
D I
S U

C
A
J
T
J
T
Z
E
W
D
J
T
Z
E
R
N

From last decipherment, we can conclude that

U will be W,H will be C, B will be Y, T will be G and G will be B,


Y
O
V
M
N
H
M
I
N
H
D
S
X
L
J
T

I
U
M
I
D
S
Y
O
Z
E
Y
O
Z
E
M
I

F
R
R
N
I
U
R
N
U
W
V
M
W
D
X
L

Q
F
Z
E
F
R
N
H
C
A
Z
E
G
B
J
T

F
R
W
D
E
P
C
A
D
S
V
M
C
A
Z
E

M
I
N
H
F
R
W
D
R
N
Y
O
H
C
W
D

Z
E
M
I
M
I
J
T
J
T
F
R
S
K
I
U

R
N
D
S
D
S
C
A
X
L
Z
E
M
I
E
P

W
D
Z
E
Z
E
S
K
Y
O
U
W
R
N
J
T

Q
F
V
M
C
A
Z
E
Y
O
M
I
N
H
Y
O

F
R
E
P
D
S
R
N
S
K
R
N
M
I
U
W

Y
O
J
T
M
I
E
P
M
I
Z
E
D
S
C
A

V
M
B
Y
Q
F
X
L
R
N
C
A
H
C
F
R

E
P
T
G
Z
E
C
A
T
G
R
N
N
H
W
D

C
A
X
L
K
V
H
C
M
I
W
D
C
A
D
S

F
R
C
A
C
A
Z
E
E
P
N
H
M
I
J
T

M
I
D
S
E
P
U
W
Y
O
Z
E
F
R
N
H

D
S
D
S
Y
O
N
H
I
U
D
S
Q
F
Z
E

Z
E
U
W
F
R
M
I
F
R
Z
E
C
A
D
S

P
X
M
I
C
A
X
L
Z
E
J
T
H
C
I
U

C
A
J
T
J
T
Z
E
W
D
J
T
Z
E
R
N

On complete decipherment of cipher text, we obtained


PLAIN TEXT as

OUR FRIEND FROM PARIS EXAMINED HIS EMPTY GLASS


WITH SURPRISE AS IF EVAPORATION HAD TAKEN PLACE
WHILE HE WASNT LOOKING I POURED SOME MORE
WINE AND WE SETTLED BACK IN HIS CHAIR FACE TILTED
UP TOWARDS THE SUN

NOTE:- All figures are from Cryptography and Network Security Principles and Practice by William

Stallings, Fifth Edition.

REFERENCES
[1] Cryptography and Network Security Principles and Practice by William Stallings, Fifth
Edition.

Вам также может понравиться