You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: 04-Protocol-Security.md
+2-15
Original file line number
Diff line number
Diff line change
@@ -150,15 +150,13 @@ The following functions will also be referenced:
150
150
151
151
## 4.5 Authenticated Key Agreement Handshake
152
152
153
-
The handshake chosen for the authenticated key exchange is an **`Noise_NX`** augmented by algorithm negotiation prior to handshake itself and server authentication with simple 2 level public key infrastructure.
153
+
The handshake chosen for the authenticated key exchange is an **`Noise_NX`** augmented by server authentication with simple 2 level public key infrastructure.
154
154
155
-
The complete authenticated key agreement (`Noise NX`) is performed in five distinct steps (acts).
155
+
The complete authenticated key agreement (`Noise NX`) is performed in three distinct steps (acts).
156
156
157
157
1. NX-handshake part 1: `-> e`
158
158
2. NX-handshake part 2: `<- e, ee, s, es, SIGNATURE_NOISE_MESSAGE`
159
159
3. Server authentication: Initiator validates authenticity of server using from `SIGNATURE_NOISE_MESSAGE`
160
-
4. Cipher upgrade part 1: Initiator provides list of alternative aead-ciphers that it supports
161
-
5. Cipher upgrade part 2: Responder confirms or dismisses upgrade to a different aead-cipher
162
160
163
161
Should the decryption (i.e. authentication code validation) fail at any point, the session must be terminated.
164
162
@@ -287,15 +285,6 @@ signature is constructed for
287
285
288
286
Signature itself is concatenation of an EC point `R` and an integer `s` (note that each item is serialized as 32 bytes array) for which identity `s⋅G = R + HASH(R || P || m)⋅P` holds.
289
287
290
-
291
-
#### 4.5.5.1 Upgrade to a new AEAD-cipher
292
-
293
-
If the server provides a non-empty `CIPHER_CHOICE`:
294
-
295
-
1. Both initiator and responder create a new pair of CipherState objects with the negotiated cipher for encrypting transport messages from initiator to responder and in the other direction respectively
296
-
2. New keys `key_new` are derived from the original CipherState keys `key_orig` by taking the first 32 bytes from `ENCRYPT(key_orig, maxnonce, zero_len, zeros)` using the negotiated cipher function where `maxnonce` is 2<sup>64</sup> - 1, `zerolen` is a zero-length byte sequence, and `zeros` is a sequence of 32 bytes filled with zeros. (see `Rekey(k)` function<sup>[8](#reference-8)</sup>)
297
-
3. New CipherState objects are reinitialized: `InitializeKey(key_new)`.
298
-
299
288
## 4.6 Encrypted stratum message framing
300
289
301
290
After handshake process is finished, both initiator and responder have CipherState objects for encryption and decryption and after initiator validated server's identity, any subsequent traffic is encrypted and decrypted with `EncryptWithAd()` and `DecryptWithAd()` methods of the respective CipherState objects with zero-length associated data.
0 commit comments