3.1.2

Encryption

Test yourself

Encryption

If sensitive data is going to be transferred, then it is important that we keep it secure from third parties.

Illustrative background for EncryptionIllustrative background for Encryption ?? "content

Encryption

  • Encrypting data is the process of scrambling data according to a specific algorithm so that it cannot be read by third parties.
  • Only the intended recipient will know how to decode the data.
Illustrative background for KeysIllustrative background for Keys ?? "content

Keys

  • A lot of encryption depends upon secret keys, which are shared secret pieces of data.
  • Keys are made up of a pair of very large prime numbers, either 256 or 1,024 bits long.
  • It would take an impractical amount of time to guess the key. So we say that the encryption is secure.
Illustrative background for Wireless communicationIllustrative background for Wireless communication ?? "content

Wireless communication

  • It is especially important to encrypt wireless communication.
  • Protocols exist for wireless communication, such as WiFi Protected Access version 2 (WPA2), which encrypt all traffic.

Symmetric and Asymmetric Encryption

The use of encryption is vital to protect our private information. One type of encryption is symmetric encryption.

Illustrative background for Symmetric encryptionIllustrative background for Symmetric encryption ?? "content

Symmetric encryption

  • Symmetric or private key encryption is used to encrypt data for transmission.
  • A private key is used to convert plain text into cypher text.
  • This cypher text and private key are then transferred to another location or person.
  • The key is then used to decrypt the cypher back into plain text.
Illustrative background for SecurityIllustrative background for Security ?? "content

Security

  • Using a single key to encrypt and decrypt text proposes a massive flaw in security, as anyone with the key can decrypt the cypher.
  • As with passwords, the longer the encryption key, the less likely it is to be compromised by brute force, and so the more secure the encryption.
Illustrative background for Asymmetric encryptionIllustrative background for Asymmetric encryption ?? "content

Asymmetric encryption

  • Asymmetric or public key encryption is a much stronger form of encryption and uses two keys: a public and a private key.
  • The public key is given to anyone who wishes to send you encrypted data.
  • This public key can only be used to encrypt information and not decrypt the information.
  • The private key is used to decrypt the data, and only you have this key.
Illustrative background for Public and private keysIllustrative background for Public and private keys ?? "content

Public and private keys

  • The public and private key are related to one another through mathematical operations.
  • The private key you set cannot be figured out from the public key.

Hashing

Hashing can be used for both protecting data and for comparing files.

Illustrative background for HashingIllustrative background for Hashing ?? "content

Hashing

  • Hashing is the process of taking an input, performing some form of calculation on the input that outputs a value of fixed size.
  • The output is known as a hash.
  • The hash function has no inverse (non-invertible).
  • This means hashing is extremely secure as you cannot reverse a hash to get back to the original data that was input.
Illustrative background for PasswordsIllustrative background for Passwords ?? "content

Passwords

  • Hashing can be used to store passwords.
  • When a user creates a password for an account, it is put through a hashing function and stored as the encrypted password.
  • A password entered by a user to gain access to the account will be put through the same hashing function and compared to the stored password.
  • No one can know your actual password by looking in the database.
Illustrative background for Digital signaturesIllustrative background for Digital signatures ?? "content

Digital signatures

  • Hashing can also be used as a way of adding digital signatures to files.
  • The hash output value can be encrypted with a private key and sent to someone else and they use the matching public key to decrypt.
  • This way you know it has come from that one specific person.

Jump to other topics

1Components of a Computer

2Software & Software Development

3Exchanging Data

4Data Types, Data Structures & Algorithms

5Legal, Moral, Cultural & Ethical Issues

6Elements of Computational Thinking

6.1Thinking Abstractly

6.2Thinking Procedurally

6.3Thinking Logically

7Problem Solving & Programming

8Algorithms

Go student ad image

Unlock your full potential with GoStudent tutoring

  • Affordable 1:1 tutoring from the comfort of your home

  • Tutors are matched to your specific learning needs

  • 30+ school subjects covered

Book a free trial lesson