Encryption

Introduction

Encryption is the method in which data can be kept secure while it is being transmitted, essentially providing intruders/interceptors with unusable nonsense. There are a few ways in which this can be achieved, though it is important to note the data is still readable, just not legible.

Key

  • 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.

Symmetric

Both computers share the same key, this is used to encrypt and decrypt the data. Getting the key is somewhat finnicky - if that key is intercepted, the whole process is worthless.

  • Both client and server share the same key
  • 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.

Asymmetric

  • 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.

This method uses the knowledge that the keys are mathematically related to each other, though it is impossible to derive one from the other still.