Question

In: Computer Science

Stream Cipher. A message is encoded by exclusive-or’ing each bit with a random bit stream. (In...

Stream Cipher. A message is encoded by exclusive-or’ing each bit with a random bit stream. (In exclusive or, 0⊕0 = 0, 1⊕0 = 1, 0⊕1 = 1, and 1⊕1 = 0.)

a. Recover the original message from the random stream and encrypted stream, by filling in the blanks in the “Recovered” and “ASCII” rows. (In the ASCII column, interpret the byte as an ASCII character and write the value in that row.)

Message:

?

?

?

?

?

?

?

?

?

?

?

?

?

?

?

?

?

?

?

?

?

?

?

?

Random

1

0

1

0

0

0

0

0

1

0

1

0

0

1

1

1

0

0

1

0

0

1

0

1

Encrypted

1

1

1

1

0

0

1

0

1

1

1

1

0

1

0

0

0

1

1

0

0

1

0

0

Recovered

ASCII

b. Write a few ways that the sender and receiver might share the “Random” stream.  Write an advantage for each way.

Solutions

Expert Solution

The message can be obtained by xor-ing encrypted and Random bits, this is possible because of the significant property possessed by XoR operation (a XOR a = 0).

So Recovered = : 0 1 0 1 0 0 1 0 0 1 0 1 0 0 1 1 0 1 0 0 0 0 0 1

Grouping the bits into bytes, we have 01010010 --> 82 --> R

01010011 --> 83 --> S

01000001 --> 65 --> A

Ways to share Random stream between sender and receiver:

1) Sender and Receiver agree on an algorithm, secret key, and parameters in advance to generate the random stream without sending it lonely at ciphertext transmission. It is an easier and more convenient way to share random streams as key.

2) They can also share the random streams with the help of asymmetric encryption, where keystream is encrypted using public-key encryption like RSA, Elgamal, etc. This method is more expensive but reliable.

3) To meet the receiver in person and share random keys before the transmission of ciphertext. This trick works better in the defense sector where interception of transmissions is highly taken care of. Although it provides highest level of security but looks impractical for real-life scenarios where huge messages are transmitted in a very short interval of time.


Related Solutions

1 Introduction A cipher is an algorithm which encrypts a message into cipher text so that...
1 Introduction A cipher is an algorithm which encrypts a message into cipher text so that it can be safely transmitted without an eavesdropper being able to (easily) read it. For the purposes of this assignment the message and ciphertext will be stored as strings of ASCII characters. Cipher algorithms always perform two tasks: encryption and decryption. The encryption process takes a “message” and “key” as inputs and produces cipher text. The decryption process performs the reverse: it turns cipher...
When a message is sent electronically it is usually sent as a stream of bits, each...
When a message is sent electronically it is usually sent as a stream of bits, each of which can be either a 0 or a 1. If the digital channel is noisy then each bit has some probability of being flipped (ie changed from a 0 to a 1 or vice versa) resulting in a corrupted message. Assume that a message is being sent through a noisy channel where the probability that any individual bit will be flipped is 0.1....
List the primitive operations used in the RC4 stream cipher algorithm for A) Key Stream Generation...
List the primitive operations used in the RC4 stream cipher algorithm for A) Key Stream Generation B) Bit Stream Encryption
A binary data stream 111010010 is to be transmitted using DPSK. Determine the encoded data and...
A binary data stream 111010010 is to be transmitted using DPSK. Determine the encoded data and phase of the DPSK o/p .
A Caesar cipher encrypts a message by shifting letters in the alphabet. For example, a shift...
A Caesar cipher encrypts a message by shifting letters in the alphabet. For example, a shift of 4 maps 'a' to 'e' and maps 'p' to 't' Here is a famous line from Shakespeare encrypted with a shift of 4: 'vq dg qt pqv vq dg: vjcv ku vjg swguvkqp.' (a) Write a program that takes as input a string to be encrypted and an integer encrpytion shift (such as 4 mentioned earlier), and prints the encrypted string. [Hint: zip()...
In practice, an LFSR sequence would not be used as keystream for a stream cipher, due...
In practice, an LFSR sequence would not be used as keystream for a stream cipher, due to the linear complexity. Answer the following questions about linear complexity. What is the linear complexity of a maximal length LFSR output sequence? Describe one method using LFSRs to produce a binary output sequence but with increased linear complexity. Draw a diagram to illustrate your construction.
Suppose Alice is using a block cipher to send the message THE ORDER IS KARL, ANDY,...
Suppose Alice is using a block cipher to send the message THE ORDER IS KARL, ANDY, FRED AND IAN. IAN AND ANDY HAVE LEFT. to Bob. Assume that the block cipher is used in ECB mode, the English is divided into plaintext blocks of 2 letters (ignore spaces and punctuation) the ciphertext blocks are denoted C1,C2,...,C23 (a) Write down the 23 plaintext blocks. (b) Will any of the ciphertext blocks be repeated? If so, which ones? (c) Suppose an attacker...
What would be the encoded version of the message using LZW compression technique xxyz xxy xxyz...
What would be the encoded version of the message using LZW compression technique xxyz xxy xxyz xxyz xxyz
Write a Java program that uses the RC4 cipher algorithm to encrypt the following message using...
Write a Java program that uses the RC4 cipher algorithm to encrypt the following message using the word CODES as the key:   Cryptography is a method of protecting information and communications through the use of codes so that only those for whom the information is intended can read and process it. Instead of using stream length 256, we will use length 26. When encrypting, let A = 0 to Z = 25. Ignore spaces and punctuations and put the message...
Find the shortest encoded bit string of the following source sequence: Source sequence: ABCCDEAFABCBEDFABCBBAEFFEBCEFF (a) using...
Find the shortest encoded bit string of the following source sequence: Source sequence: ABCCDEAFABCBEDFABCBBAEFFEBCEFF (a) using extended Huffman coding to encode the string where k=2 (b) using arithmetic coding.For this case, you can ignore the termination issue ina a decoder, and output the shortestbit string of the first 5 symbols only, while the probability distribution is based on the whole sequence. (c) Using adaptive Huffman coding to encode the first 10 symbols of the string. The initial code assignment is...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT