Chap 2.2 / 3 - Data transmission (error checking, encryption) Flashcards
types of error checking
-Cyclic Redundancy Checks (CRC)
-Check digit (ISBN-13 / Modulo 11)
-Checksum
-Echo check
-Parity Checks
-Automatic Repeat Request (ARQs)
which error checking check following transmission
-parity checks
-echo checks
-checksum
-ARQs
define CRC
-type of error checking where the no. of 1’s are counted and put as a Hex value in the trailer to be sent
how does CRC work
-count no. 1’s
-put value as Hex in the trailer
-receiving comp counts no. 1’s & CRC
-if match = no error; no match = error & packet resent
why do you need to check for errors
-risk that data may be tampered with during transmission
Errors can occur due to:
-interference = all cables can suffer from electrical interference
-problems during packet switching
-skewing of data = in parallel transmission, bits arrive out of sync
define parity checking
-type of error checking where a parity bit is added based on the chosen parity system
define parity bit
-extra bit added based on the chosen parity system
how does Parity Check work
-choose even or odd
even:
-count no. 1’s
-if even, parity bit = 0; if odd, parity bit = 1
odd:
-count no. 1’s
-if odd, parity bit = 0; if even, parity bit = 1
-receiving comp checks if no. 1’s matched chosen parity system
how to find faulty bit in parity check
-Criss cross method
-count no. 1’s in each column & row (parity bit & byte), find one that doesn’t match chosen parity system
-find intersection point
-can determine which digital stream was changed
define checksum
-type of error checking where a checksum is calculated form the data using and agreed algorithm & transmitted with the data
how does checksum work
-calculate checksum from agreed algorithm
-checksum is sent with data
-receiving comp recalculates checksum & compares them
-if match = no error; no match = error & resend
define Echo check
-type of error checking where sent data is sent back to sender to check if any error occurred during transmission
how does echo check work
(don’t know if error happened at 1 / 2 transmission)
-data is sent
-copy of data is sent back to sender
-returned & og data are compared
-no diff = no error, yes diff = yes error
define check digit
-final digit in code calculated from all other digits in the code
types of check digit
-ISBN-13
-Modulo 11
what can check digits identify
-incorrect digit entered
-transposition error occurred
-omitted or extra digits
-phonetic errors
how is check digit used
-check digit is calculated by human & added to code
-human types numerical code
-comp. calculate check digit based on numerical code & compare with human check digit
-no match = human made an error
-asked to re-enter code
ISBN 13 algorithm
1)from left to right, first digit is odd
2)-add all no.s in odd index sequence
2)-add all no.s in even index sequence x 3
3)- 1) + 2) / 10
4)- if remainder = 0, use
5)- else 10- remainder
6) do same for recalculation, 0 = corret transmission
Modulo-11 algorithm (generation)
1)-each digit has weighting starting from 2 from right
2)-each digit x their weighting and add all
3)-total / 11
4)-if remainder = 10, check digit = X
5)-else 11- remainder
Modulo-11 algorithm (recalculation)
1)-each digit has weighting starting from 1 from right to end
2)-each digit x their weighting and add all
3)-total / 11
4)-if remainder = 0, no. is correct
diff btw Checksum & check digit
checksum:
-calculated from block of data
-sent with block of data
-recalculated at receiving
-if diff = error occurred
-used to check errors flowing data transmission
check digit:
-final digit in code
-calculated form other digits in code
-used to check errors during data entry
-detects, incorrect digit entered, transposition error occurred, omitted or extra digits, phonetic errors
define ARQs
-type of error checking where an ( - )/( + ) acknowledgment is sent within the timeout before the data is resent
how does ARQs work
-data is sent to receiver with an error detection code
-no error = ( + ) acknowledgment, no resend
-yes error = ( - ) acknowledgment, yes resend
-no acknowledgment within timeout = yes resend
define acknowledgement in ARQS
-message sent to sender indicated if data had errors during transmission
define timeouts in ARQS
time interval allowed to elapse before an acknowledgment is received
define plain text
-og messge
define cipher text
-texts following and encryption algorithm
why is encryption used
-to make data transmission safe
-no interception guaranteed but data will make no sense
types of encryption
-symmetric
-asymmetric
define pub. key
-key known to all users
define pvt. key
-key used to decrypt for asymmetric encryption
define shared secret
-key used to encrypt & decrypt for symmetric encryption
how does symmetric encryption work
-public key is used to encrypt & decrypt plain & cipher texts btw Alice & bob
-2 pub keys
how does asymmetric encryption work
-Alice gives out pub. key to Bob to encrypt plain text
-cipher text is decrypted using Alice’s pvt. key
-only Alice has pvt. key
-pub, & pvt, keys are mathematically linked tgt
-pub & pvt key
how does end-to-end encryption work
-Alice & Bod each have pub. & pvt. keys
-they send pub. keys
cipher text send to each other can be decrypted by their own pvt. key
describe a situation where parity check wouldn’t identify which bit has been transmitted incorrectly
-even/ odd no. errors so if (parity type) retained
eg, 2 bits have changed
how does encryption improve security
-encrypted text is meaningless
-need a key to decrypt
how to make encryption more secure
-add more bits to the key so less chance of decryption by brute force
3 differences between symmetric & asymmetric encryption
-sym uses the same keys for encryption and decryption but asym uses 2 different keys for encryption and decryption
-asym has a pvt key but sym does not
-asym is used for secure key exchange but sym is used for bulk data transmission
how does a data logger calculate the parity bit
-count the number of 1’s in the first 7 bits
-add a 0 or 1 depending on the parity type
role of parity byte in error detection
It provides a means to check for errors by ensuring that the total number of 1s in the byte is even or odd
disadvantage of symmetric encryption
security problem when transmitting encryption key
define symmetric encryption key
-sender & receiver use same key to encrypt & decrypt message