Chapter 4 Flashcards

1
Q

Most common encoding standard?

A

ASCII

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is the problem with unicode?

A

All devices that were built before unicode couldnt communicate

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

How does one specify which charsets to use?

A

Accept-Charset: iso-8859-1

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

How do you show how many octets there will be in a UTF encoding string

A

0 = lower 7 bits represent the character
10 = continuation character
110 = 1 octet will follow
1110 = 2 octets will follow
11110
111110
1111110
1111110

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is the limit of bytes per character in UTF-8?

A

4 bytes per character

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is mean by “UTF-8 is self synchronising”?

A

If there is a mistake skip over all of the 10 starting octets and go to a 0 or 11* octet

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What does *;q=0.1 mean in Accept-Charset?

A
  • = wildcard. q = quality(preference)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What are the 3 basic constructor types in ASN.1?

A

CHOICE, SEQUENCE, SET

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

In what representation are X.509 certificates defined?

A

ASN.1

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Whats the difference between XML and ASN.1

A

ASN.1 provides abstract description of what the data looks like.

ASN.1 is more compact ( thus less resource intensive )

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Which is easier to inspect, ASN.1 or XML and why?

A

XML because ASN.1 message may contain binary data

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What does ASN provide in terms of the message to be sent?

A

It provides an abstraction of the message

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What does BER use as a type descriptor at the start of any value?

A

A octet

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

SOAP is a ……….. representation

A

application oriented

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What representation is used for web services?

A

WSDL ( Web service description language )

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

When does the presentation layers negotiate which representation to use?

A

Before the actual data is sent

17
Q

What does MIME data consist of?

A

Header and payload

18
Q

What are the 2 important headers for MIME?

A

Content-Type
Content-Transfer-Encoding

19
Q

What are the MIME types?

A

application
Audio
example
image
message
model
multipart ( composite payloads)
Text
video

20
Q

How do you specify which character set to use in MIME?

21
Q

Is the data represented by the presentation layer already encoded?

22
Q

What is the mime type for audio/music?

A

audio/mpeg

23
Q

Whats the problem with universal formats?

A

Should it have minimal/ most common features or a truly universal format.

24
Q

Problems with data exchange?

A

Formats ( interoperability)
Large datasets migration
integrity

25
How can we solve data exchange challenges?
Use container formats. Use data serialization. Interchange formats (ASN XML)
26
What is the difference between lossy and loss less compressions?
Lossy = looses some info during compression Lossless
27
On what level does compression happen?
Layer 6
28
What is run length encoding?
Shortening "runs" by compressing it
29
Example of RLE ( Run length encoding with characters) Ng[[[[[[[[[[[[[[[[[[[[[[[[[[[[
Ng[[[[[[[[[[[[[[[[[[[[[[[[[[[[ (N,G,"",28,[) No "
30
(N,G,,28,[) What is
A character to denote that a run will occur
31
Steps of bit-based RLE
1: count consecutive bits (assuming starting with 0) (if there are no 0;s == 0 2: Encode run lengths
32
Bit-based RLE Example: Original: 000011100000111000000
Original: 000011100000111000000 1: 4,3,5,3,6 2: 0100(4) 0011(3) 0101(5) 0011(3) 0110(6)
33
How does Lempel-Ziv compression work?
Replace repeated patterns with shorter codes. Computational complexity may play a factor
34
Watch video on Huffman codes
35
What is the main idea behind huffman codes?
Most used characters = shortest code
36
How do we construct a huffman tree?
1: Treat each letter as a single node tree. 2: Join 2 trees at a time until only 1 left 3: combine the 2 trees that are used least frequently
37
Is huffman code self-synchronising?
No
38
Why is the lower layer we usually could encrypt at level 2 and not layer 1?
Cause layer 1 doesnt add any headers.
39
What is the problem with link encryption? ( Layer 2 encryption)
Youd have to decrypt at every single node