1.3.1 Compression, encryption and hashing Flashcards

You may prefer our related Brainscape-certified flashcards:
1
Q

compression

A

Compression is the process used to reduce the storage space required by a file, meaning you can store more files with the same amount of storage space. Compression is particularly important for sharing files over networks or the Internet. The larger a file, the longer it takes to transfer and so compressing files increases the number of files that can be transferred in a given time.

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

lossy compression

A

-original file cannot be restored as it permanently deletes data

-Algorithm used to strip out least important data

-examples-JPEG, MP3, MPEG

-typically used for multimedia files

-images

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

lossless compression

A

-original file can be restored as it doesnt permanently delete data

-typically less effective at reducing file size

-examples- ZIP, PNG, GIF

-essential for some file types such as computer programs

-audio

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

Run Length Encoding

A

This method is ideal for compressing bitmap images, contiguous pixels of the same colour.​

Sometimes called RLE, run length encoding is a method of lossless compression in which repeated values are removed and replaced with one occurrence of the data followed by the number of times it should be repeated.

For example, the string AAAAAABBBBBCCC could be represented as A6B5C3.

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

Dictionary Coding

A

Works by building an index that we visualise as a table and every data or entry in the file is recorded​.

Dictionary encoding is another example of a method of lossless compression. Frequently occurring pieces of data are replaced with an index and compressed data is stored alongside a dictionary which matches the frequently occurring data to an index. The original data can then be restored using the dictionary.

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

Run Length Encoding disadvantage

A

In order to work well, run length encoding relies on consecutive pieces of data being the same - if there’s little repetition, run length encoding doesn’t offer a great reduction in file size.

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

encryption

A

The process of encoding a message so it can be read only by the sender and the intended recipient.​

Encryption is used to keep data secure when it’s being transmitted. There are a variety of different methods which can be used to scramble data before it’s transmitted and then decipher it once it arrives at its destination.

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

Symmetric Encryption

A

A single key is used to both encrypt and decrypt a message.​

In symmetric encryption, both the sender and receiver share the same private key, which they distribute to each other in a process called a key exchange. This key is used for both encrypting and decrypting data.

It’s important that the private key is kept secret. If the key is intercepted during the key exchange then any communications sent can be intercepted and decrypted using the key. Asymmetric encryption gets around this issue.

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

Asymmetric Encryption

A

When sending information using asymmetric encryption, two keys are used: one public and a second, private, key. Something which is encrypted with one of the keys can only be decrypted with the other key. For example, if a document is encrypted with the public key, only the private key could be used to decrypt the document.

The public key can be published anywhere, free for the world to see, while the private key
must be kept secret. Together, these keys are known as a key pair.

Asymmetric encryption is based on everyone having their own key pair. They publish their
public keys online on a special website and keep their private key to themselves.

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

Hashing

A

Transforms a string of characters into a fixed-length value or key that represents the original input string.

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

Hashing advantage

A

Unlike encryption, the output of a hash function can’t be reversed to form the key. This quality makes hashing useful for storing passwords. A password entered by a user can be hashed and checked against the key to see if it is correct, but a successful hacker would only gain access to the keys, which can’t be reversed to gain the passwords.

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

properties of hashing

A

-low chance of collisions
-quick to calculate
-output smaller than input

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