P a g e | 1
Question 1: What is the drawback of VRC
Vertical Redundancy Check is a way of error checking by attaching a parity bit to each byte of data to be transmitted, which is then tested to determine if the transmission is correct.
The resulting parity bit is constructed by XORing the word. The result is a "1" if there is an odd number of 1s, and a "0" if there is an even number of 1s in the word.
This method is unreliable, because if there are even number of errors in the data, the error
will go undetected.
Question 2: Calculate the LRC of the following data: [HEX] 864C9BF3
In telecommunication, a longitudinal redundancy check (LRC) or horizontal redundancy check is a form of redundancy check that is applied independently to each of a parallel group of bit streams. The data must be divided into transmission blocks, to which the additional check data is added.
Data: 1000 0110 0100 1100 1001 1011 1111 0011
1 0 0 0 0 1 1 0 0 1 0 0 1 1 0 0 1 0 0 1 1 0 1 1 1 1 1 1 0 0 1 1 1 0 0 0 (Parity bit calculated for every column)
Transmitted Data: 1000 0110 0100 1100 1001 1011 1111 0011 1000
P a g e | 2
Question 3: A: For P=110101 and M=1011010001, Find CRC?
B: In CRC error Detection scheme, choose P(x)=x 4
+x+1. Encode the bits
1 1 0 1 1 0 1
110101 / 1 0 1 1 0 1 0 0 0 1 0 0 0 0 0 1 1 0 1 0 1 : : : : : : : : :
0 1 1 0 0 0 0 : : : : : : : : 1 1 0 1 0 1 : : : : : : : : 0 0 0 1 0 1 0 0 1 : : : : : 1 1 0 1 0 1 : : : : : 0 1 1 1 0 0 0 : : : :
1 1 0 1 0 1 : : : : 0 0 1 1 0 1 0 0 : : 1 1 0 1 0 1 : : 0 0 0 0 0 1 0 0 <= FCS
The FCS is: X2
Transmitted bits: 1 0 1 1 0 1 0 0 0 1 0 0 1 0 0
1 1 0 1 0 1 1
10011 / 1 0 1 1 1 0 1 1 0 1 1 0 0 0 0 1 0 0 1 1 : : : : : : : : : :
0 0 1 0 0 0 1 : : : : : : : : 1 0 0 1 1 : : : : : : : : 0 0 0 1 0 1 0 1 : : : : : 1 0 0 1 1 : : : : : 0 0 1 1 0 1 0 : : :
1 0 0 1 1 : : : 0 1 0 0 1 0 : : 1 0 0 1 1 : : 0 0 0 0 1 0 0 <= FCS
Predetermined Divisor: 10011
FCS = X3
Transmitted bits: 1 0 1 1 1 0 1 1 0 1 1 0 1 0 0
P a g e | 3
Question 4: Calculate the hamming pair wise distance among the following codewords: A: 00000, 10101, 01010
B: 000000, 010101, 101010, 110110
Let V1 = 0 0 0 0 0
V2 = 1 0 1 0 1
V3 = 0 1 0 1 0
D(V1,V2) = 3 D(V1,V3) = 2 D(V2,V3) = 5
Let V1 = 0 0 0 0 0 0
V2 = 0 1 0 1 0 1
V3 = 1 0 1 0 1 0
V4 = 1 1 0 1 1 0
D(V1,V2) = 3 D(V1,V3) = 3 D(V1,V4) = 4 D(V2,V3) = 6 D(V2,V4) = 3
D(V3,V4) = 3
Question 5: Suppose a file of 8,000 bytes is to be sent over a line of 5600 bps. A: Calculate the overhead in bits and time in using asynchronous communication. Assume one start bit and a stop bit element of length one bit, and 8bits to send the byte itself for each character. The 8 –bit character consists of all data bits with no parity bit.
B: Calculate the overhead in bits and time using synchronous communication. Assume that the
data are sent in frames. Each frame consists of 1000 characters = 8000 bits and overhead of 48
control bits per frame.
P a g e | 4
Number of Bytes = 8000
Number of bits = 8 x 8000 = 64000
Line capacity = 5600 bps
Start bit length = 1 bit
Stop bit Length = 1 bit
Number of bits for 1 character = 8 bits
Bits apart from data = 2 bits per character (i.e. 2 bits for every byte)
Total bits apart from data = 2 x 8000 = 16000 bits
Total bits transmitted = 64000 + 16000 = 80000
Therefore, the overhead ratio = (Number of extra bits) / (Total Number of bits Transmitted)
= 16000 / 80000
Percentage overhead = 0.2 x 100 % = 20 % (in bits)
Time overhead = 16000/5600 = 2.85 sec
Number of data bits per frame = 8000
Total frames in 8000 bytes = 64000/8000 = 8 frames
Control bits per frame = 48
Total number of overhead bits = 48 x 8 = 384 bits
Therefore, the overhead ratio = (Number of control bits) / (Total Number of bits Transmitted)
= 384 / 64384
= 0.00596 = 0.006
Percentage overhead = 0.006 x 100 % = 0.6 % (in bits)
Time overhead = 384/5600 = 68 ms
A: Consider the use of 1500-bit frames on a 1-Mbps satellite channel with a 270-ms delay. What is the maximum link utilization for?
a: Stop-and-wait flow control?
P a g e | 5
b: Continuous flow control with a window size of 7?
c: Continuous flow control with a window size of 127?
d: Continuous flow control with a window size of 255?
B: In figure
frames are generated at node A and sent to node C through node B. determine the minimum data rate required between nodes B and C so that the buffers of node B are not flooded, based on the following:
a) The data rate between A and B is 100Kbps.
b) The propagation delay is 5micro seconds per kilometer for both lines.
c) There are full-duplex lines between the nodes.
d) All data frames are 1000 bits long; ACK frames are separate frames of negligible length.
e) Between A and B, a sliding-window protocol with a window size 3 is used.
f) Between B and C, Stop-and-wait is used.
g) There are no errors.
Bits/frame = 1500 bits / frame
Data rate = R = 1Mbps = 1000000 bits / sec
Propagation Delay = 270 ms = 0.27 sec
Link Utilization for stop and wait flow control is given by:
Where a = tprop / tframe
tframe = (Bits/frame) / R = 1.5 x 10 -3 sec / frame
P a g e | 6
a = 180 => U = 0.00277
Link Utilization for continuous flow control is given by:
Where W is the window size.
For a window size of 7:
=> U = 0.0193
For a window size of 127:
=> U = 0.35
For a window size of 255:
=> U = 0.706
From A to B:
R = 100 kbps, Window size = W = 3, Propagation time / km = 5 usec / km
Frame size = 1000 bits
tprop = 4000 x 5 usec = 20 ms
tframe = 1000 / 100000 = 10 ms
Since the window size between A and B is 3, therefore, A can transmit three frames to B and then
must wait for the acknowledgment of the first frame before transmitting additional frames.
Time taken by A to transmit 3 frame = T
T = (2 x tprop) + tframe = 50 ms
From B to C:
tprop = 1000 x 5 usec = 5 ms
tframe = 1000 / R
B can transmit one frame at a time to C. The time taken to transmit 1 frame and get back the
acknowledgement is T:
T = T = (2 x tprop) + tframe = tframe + 10 ms
P a g e | 7
Therefore, it will take 3tframe + 30 ms to transmit 3 frames transmitted by A,
3tframe + 30 ms = 50 ms tframe = 6.66 ms
Since R = 1000 / tframe => R = 150 kbps
Question 7: No mention was made of reject (REJ) frames in the stop-and-wait
ARQ discussion. Why it is not necessary to have REJ0 and REJ1 for stop-and-wait
Stop-and-wait ARQ is the simplest kind of automatic repeat-request (ARQ) method. A stop-
and-wait ARQ sender sends one frame at a time. After sending each frame, the sender doesn't
send any further frames until it receives an ACK (acknowledgement) signal. After receiving a
good frame, the receiver sends an ACK. If the ACK does not reach the sender before a certain
time, known as the timeout, the sender sends the same frame again.
If the receiver sees that the frame is good, it sends an ACK. If the receiver sees that the frame
is damaged, the receiver discards it and does not send an ACK -- pretending that the frame
was completely lost, not merely damaged. Hence this timeout acts as a reject signal for the
transmitter. The transmitter simply sends the same frame.
Question 8: Find link utilization of the following scenarios
A: WAN using ATM with two stations a thousand kilometers apart. Frame size is 424 bits and
data rate is 155.52Mbps. Speed of signal is 2*10 8
B: LAN with two stations 100 meters apart. Frame size is 1000bits and data rate is 100Mbps.
Speed of signal is 2*10 8
Stop and Wait ARQ:
REJ0 and REJ1 Not necessary:
P a g e | 8
Given that: Data rate = R = 155.52 Mbps Distance = d = 1000 km Speed of the signal = V = 2 x 108 m/s Frame size = L = 424 bits length of the link in bits: B = R * (d / V) = 720000000 bits
a = (B / L) = 720000000 / 424 = 1.69 x
U = ( ) = ( ) => U = 2.95 x 10-7
Given That: Data rate = R = 100 Mbps Distance = d = 100 m Speed of the signal = V = 2 x 108 m/s Frame size = L = 1000 bits Now, for length of the link in bits:
B = R * (d / V) = 46.29 x bits
a = (B / L) = 720000000 / 1000 = 46.29 x
U = ( ) = ( ) => U = 1.08 x 10-5
Question 9: “When will you reach home”
Generate Huffman code?
Total Characters = 24 Frequencies: a = 1, c = 1, e = 3, h = 3, i = 1, l = 2, m = 1, n = 1, o = 2, r = 1, u = 1, y = 1, w = 2, space = 4 Respective Probabilities: = 1/24, 1/24, 1/8, 1/8, 1/24, 1/12, 1/24, 1/24, 1/12, 1/24, 1/24, 1/24, 1/12
P a g e | 9
Arranging according to frequencies: Space : 4 e: 3 h: 3 l: 2 0: 2 w: 2 a: 1 c: 1 i: 1 m: 1 n: 1 r: 1 u: 1 y: 1
P a g e | 10
Question 10: What are the dangers involved in internet communication? Clarify with example?
The Internet has its origins in a research project of the American administration in the late sixties; the development goal was to establish the most robust and reliable networking possible between relatively few university computer centres. The security and confidentiality of communication played a minor role at that time. This still has an effect on the Internet today with its hundreds of millions of users worldwide. 1. Spying out information Information is generally transported across a large number of network nodes and transmission links on the Internet, where it can be read relatively easily by third parties. 2. Corrupting information, pretending a false identity During their transport through the Internet data can be modified unnoticed by the recipient. Sender details in e-mails and computer addresses can also be falsified. You thus cannot be sure of the identity of your communication partner and the authenticity of the information received. 3. Implanting harmful programs Together with seemingly harmless information (e-mail, websites) harmful programs (viruses, worms, Trojan horses, ...) are sometimes sent or offered on the Internet, which in most cases can implant themselves unnoticed on your computer and cause damage there. 4. Unauthorized penetration into computers Even if you do not actively communicate yourself, your computer is in danger of being misused by unauthorized third parties (’hackers’), if there is a connection to the Internet. Hackers often exploit faults in the operating and application software to clandestinely implant harmful programs through the network, which often enable complete control of the computer. Via such Trojan horses it is also possible, for example, to log keyboard strokes and send them to the hacker, who can thus obtain information extremely worth being protected (e.g. passwords, PIN). 5. Disclosure of personal information In communicating on the Internet, on the one hand, you always leave information at different places, which allows conclusions to be drawn concerning your person and your communication behaviour (name, Internet address, type and amount of retrieved information etc.). On the other hand, you are often actively requested to enter sensitive information. It should be noted
P a g e | 11
here that adequate data protection provisions penalizing a misuse of personal data are not effective in all countries.
Question 11: Illustrate how digital signatures work by giving an example? A digital code that can be attached to an electronically transmitted message that uniquely identifies the sender. Like a written signature, the purpose of a digital signature is to guarantee that the individual sending the message really is who he or she claims to be. Digital signatures are especially important for electronic commerce and are a key component of most authentication schemes. To be effective, digital signatures must be unforgeable. There are a number of different encryption techniques to guarantee this level of security.
Step 1: Calculate the Message Digest
In the first step of the process, a hash-value of the message (often called the message digest) is calculated by applying some cryptographic hashing algorithm (for example, MD2, MD4, MD5, SHA1, or other). The calculated hash-value of a message is a sequence of bits, usually with a fixed length, extracted in some manner from the message.
Step 2: Calculate the Digital Signature
In the second step of digitally signing a message, the information obtained in the first step hash-value of the message (the message digest) is encrypted with the private key of the person who signs the message and thus an encrypted hash-value, also called digital signature, is obtained. For this purpose, some mathematical cryptographic encrypting algorithm for calculating digital signatures from given message digest is used. The most often used algorithms are RSA (based on the number theory), DSA (based on the theory of the discrete logarithms), and ECDSA (based on the elliptic curves theory).
P a g e | 12
Step 1: Calculate the Current Hash-Value
In the first step, a hash-value of the signed message is calculated. For this calculation, the same hashing algorithm is used as was used during the signing process. The obtained hash- value is called the current hash-value because it is calculated from the current state of the message.
Step 2: Calculate the Original Hash-Value
In the second step of the digital signature verification process, the digital signature is decrypted with the same encryption algorithm that was used during the signing process. The decryption is done by the public key that corresponds to the private key used during the signing of the message. As a result, we obtain the original hash-value that was calculated from the original message during the first step of the signing process (the original message digests).
Step 3: Compare the Current and the Original Hash-Values
In the third step, we compare the current hash-value obtained in the first step with the original hash-value obtained in the second step. If the two values are identical, the verification if successful and proves that the message has been signed with the private key that corresponds to the public key used in the verification process. If the two values differ from onr another, this means that the digital signature is invalid and the verification is unsuccessful.
P a g e | 13
Question 12: Search on the web to find out exact procedure of encryption using
A: DES (Even Reg Number)
B: RSA (Odd Reg Number)
Show all steps by using example. You can use any data to demonstrate?
The DES, which is a block cipher, is the most widely known encryption algorithm. A "block cipher" refers to a cipher that encrypts a block of data all at once, and then goes on to the next block. In block encryption algorithms, the plaintext is divided into blocks of fixed length which are then enciphered using the secret key. The DES is the algorithm in which a 64-bit block of plaintext is transformed (encrypted/enciphered) into a 64-bit ciphertext under the control of a 56-bit internal key, by means of permutation and substitution. The key is given in a 64-bit word, of which eight are parity bits, at locations 8, 16, 24,…, 64. The algorithm consists of 16 "rounds" of operations that mix the data and key together in a prescribed manner using the fundamental operations of permutation and substitution.
P a g e | 14
Key Generation Algorithm
1. Generate two large random primes, p and q, of approximately equal size such that their product n = pq is of the required bit length, e.g. 1024 bits. [See note 1].
2. Compute n = pq and (φ) phi = (p-1)(q-1). 3. Choose an integer e, 1 < e < phi, such that gcd(e, phi) = 1. [See note 2]. 4. Compute the secret exponent d, 1 < d < phi, such that ed ≡ 1 (mod phi). [See note 3]. 5. The public key is (n, e) and the private key is (n, d). Keep all the values d, p, q and phi
n is known as the modulus. e is known as the public exponent or encryption exponent or just the exponent. d is known as the secret exponent or decryption exponent.
Sender A does the following:-
1. Obtains the recipient B's public key (n, e). 2. Represents the plaintext message as a positive integer m [see note 4]. 3. Computes the ciphertext c = me mod n. 4. Sends the ciphertext c to B.
P a g e | 15
Recipient B does the following:-
1. Uses his private key (n, d) to compute m = cd mod n. 2. Extracts the plaintext from the message representative m.