Add input from Wiktor

This commit is contained in:
Heiko Schaefer 2023-09-28 16:02:30 +02:00
parent 3ef4f265d1
commit eef2a11842
No known key found for this signature in database
GPG key ID: 4A849A1904CCBD7D
4 changed files with 63 additions and 9 deletions

View file

@ -13,6 +13,8 @@
https://en.wikipedia.org/wiki/Cryptographic_hash_function
Note: hashes are sometimes called "digests".
## Symmetric-key cryptography
[Symmetric-key cryptography](https://en.wikipedia.org/wiki/Symmetric-key_algorithm) uses the same cryptographic key for both encryption and decryption. Symmetric-key cryptographic systems support *encryption/decryption* operations.
@ -25,6 +27,10 @@ Participants in symmetric-key operations need to exchange the shared secret over
- visualization? (maybe a black key icon, following wikipedia's example?)
```
Symmetric-key cryptography is much faster than public-key cryptography. Also, unlike traditional public-key mechanisms, symmetric-key cryptography is quantum-resistant.
So there is a trade-off: Symmetric-key has major benefits, but exchanging the shared secret is a problem that needs to be solved separately. [Hybrid cryptosystems](hybrid_cryptosystems) are one common approach.
### Symmetric-key cryptography in OpenPGP
Symmetric cryptography is used in OpenPGP as part of a [hybrid cryptosystem](https://en.wikipedia.org/wiki/Hybrid_cryptosystem).
@ -33,6 +39,11 @@ Where symmetric keys are used in OpenPGP, they are referred to as "session keys.
### Authenticated encryption with associated data (AEAD)
```{admonition} TODO
:class: warning
- AEAD solves the problem of malleability.
```
## Public-key, or asymmetric cryptography
@ -50,6 +61,13 @@ In many places, we'll deal with asymmetric cryptographic key pairs:
An asymmetric cryptographic key pair
```
```{admonition} VISUAL
:class: warning
- Wiktor notes: red-green color-blindness affects 8,5% of the population.
- Heiko: maybe use colors + distinct shapes for the two key halves?
```
An asymmetric cryptographic key pair consists of a public and a private part. In this document, we'll show the public part of key pair in green, and the private part in red.
We'll usually visualize cryptographic key pairs in this more compact form:
@ -77,6 +95,7 @@ OpenPGP makes heavy use of public-key cryptography.
Note that, for historical reasons, OpenPGP often uses the terms "public/secret" instead of "public/private." The OpenPGP RFC and other documentation often use the non-standard term "secret key" instead of the more common "private key."
(hybrid_cryptosystems)=
## Hybrid cryptosystems
[Hybrid cryptosystems](https://en.wikipedia.org/wiki/Hybrid_cryptosystem) combine public-key cryptosystems with symmetric-key cryptosystems in a way that makes use of their respective advantages.