Skip to content

Commit

Permalink
Merge pull request stratum-mining#94 from Shourya742/aes-gcm-removal-…
Browse files Browse the repository at this point in the history
…from-protocol-md

remove aes-gcm mention from protocol.md
  • Loading branch information
rrybarczyk authored Aug 27, 2024
2 parents cc29156 + efce7a5 commit 1287973
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions 04-Protocol-Security.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,10 +93,10 @@ CipherState has the following interface:
- Sets `k = key`, `n = 0`
- `EncryptWithAd(ad, plaintext)`
- If `k` is non-empty, performs `ENCRYPT(k, n++, ad, plaintext)` on the underlying cipher function, otherwise returns `plaintext`. The `++` post-increment operator applied to `n` means: "use the current n value, then increment it".
- Where `ENCRYPT` is an evaluation of `ChaCha20-Poly1305` (IETF variant) or `AES-GCM` with the passed arguments, with nonce `n` encoded as 32 zero bits, followed by a _little-endian_ 64-bit value. Note: this follows the Noise Protocol convention, rather than our normal endian.
- Where `ENCRYPT` is an evaluation of `ChaCha20-Poly1305` (IETF variant) with the passed arguments, with nonce `n` encoded as 32 zero bits, followed by a _little-endian_ 64-bit value. Note: this follows the Noise Protocol convention, rather than our normal endian.
- `DecryptWithAd(ad, ciphertext)`
- If `k` is non-empty performs `DECRYPT(k, n++, ad, plaintext)` on the underlying cipher function, otherwise returns ciphertext. If an authentication failure occurs in `DECRYPT()` then `n` is not incremented and an error is signaled to the caller.
- Where `DECRYPT` is an evaluation of `ChaCha20-Poly1305` (IETF variant) or `AES-GCM` with the passed arguments, with nonce `n` encoded as 32 zero bits, followed by a _little-endian_ 64-bit value.
- Where `DECRYPT` is an evaluation of `ChaCha20-Poly1305` (IETF variant) with the passed arguments, with nonce `n` encoded as 32 zero bits, followed by a _little-endian_ 64-bit value.

### 4.4.2 Handshake Operation

Expand Down

0 comments on commit 1287973

Please sign in to comment.