I2P Address: [http://git.idk.i2p]

Skip to content
Snippets Groups Projects
Unverified Commit a41b8bfd authored by zzz's avatar zzz
Browse files

prop. 169 updates

parent a409df83
No related branches found
No related tags found
No related merge requests found
...@@ -5,7 +5,7 @@ Post-Quantum Crypto Protocols ...@@ -5,7 +5,7 @@ Post-Quantum Crypto Protocols
:author: zzz, orignal, drzed, eyedeekay :author: zzz, orignal, drzed, eyedeekay
:created: 2025-01-21 :created: 2025-01-21
:thread: http://zzz.i2p/topics/3294 :thread: http://zzz.i2p/topics/3294
:lastupdated: 2025-03-23 :lastupdated: 2025-03-25
:status: Open :status: Open
:target: 0.9.80 :target: 0.9.80
...@@ -522,12 +522,14 @@ For Alice: ...@@ -522,12 +522,14 @@ For Alice:
// EncryptAndHash(encap_key) // EncryptAndHash(encap_key)
ciphertext = ENCRYPT(k, n, encap_key, ad) ciphertext = ENCRYPT(k, n, encap_key, ad)
n++
MixHash(ciphertext) MixHash(ciphertext)
For Bob: For Bob:
// DecryptAndHash(ciphertext) // DecryptAndHash(ciphertext)
encap_key = DECRYPT(k, n, ciphertext, ad) encap_key = DECRYPT(k, n, ciphertext, ad)
n++
MixHash(ciphertext) MixHash(ciphertext)
...@@ -632,11 +634,13 @@ For IK: After the 'es' message pattern and before the 's' message pattern, add: ...@@ -632,11 +634,13 @@ For IK: After the 'es' message pattern and before the 's' message pattern, add:
This is the "e1" message pattern: This is the "e1" message pattern:
(encap_key, decap_key) = PQ_KEYGEN() (encap_key, decap_key) = PQ_KEYGEN()
// EncryptAndHash(encap_key)
// AEAD parameters // AEAD parameters
k = keydata[32:63] k = keydata[32:63]
n = 0 n = 0
ad = h ad = h
ciphertext = ENCRYPT(k, n, encap_key, ad) ciphertext = ENCRYPT(k, n, encap_key, ad)
n++
// MixHash(ciphertext) // MixHash(ciphertext)
h = SHA256(h || ciphertext) h = SHA256(h || ciphertext)
...@@ -644,6 +648,10 @@ This is the "e1" message pattern: ...@@ -644,6 +648,10 @@ This is the "e1" message pattern:
End of "e1" message pattern. End of "e1" message pattern.
NOTE: For the next section (payload for XK or static key for IK),
the keydata and chain key remain the same,
and n now equals 1 (instead of 0 for non-hybrid).
{% endhighlight %} {% endhighlight %}
...@@ -661,17 +669,23 @@ For IK: After the 'es' message pattern and before the 's' message pattern, add: ...@@ -661,17 +669,23 @@ For IK: After the 'es' message pattern and before the 's' message pattern, add:
{% highlight lang='text' %} {% highlight lang='text' %}
This is the "e1" message pattern: This is the "e1" message pattern:
// DecryptAndHash(encap_key_section)
// AEAD parameters // AEAD parameters
k = keydata[32:63] k = keydata[32:63]
n = 0 n = 0
ad = h ad = h
encap_key = DECRYPT(k, n, encap_key_section, ad) encap_key = DECRYPT(k, n, encap_key_section, ad)
n++
// MixHash(encap_key_section) // MixHash(encap_key_section)
h = SHA256(h || encap_key_section) h = SHA256(h || encap_key_section)
End of "e1" message pattern. End of "e1" message pattern.
NOTE: For the next section (payload for XK or static key for IK),
the keydata and chain key remain the same,
and n now equals 1 (instead of 0 for non-hybrid).
{% endhighlight %} {% endhighlight %}
...@@ -691,6 +705,7 @@ This is the "ekem1" message pattern: ...@@ -691,6 +705,7 @@ This is the "ekem1" message pattern:
(kem_ciphertext, kem_shared_key) = ENCAPS(encap_key) (kem_ciphertext, kem_shared_key) = ENCAPS(encap_key)
// EncryptAndHash(kem_ciphertext)
// AEAD parameters // AEAD parameters
k = keydata[32:63] k = keydata[32:63]
n = 0 n = 0
...@@ -719,6 +734,7 @@ After the 'ee' message pattern (and before the 'ss' message pattern for IK), add ...@@ -719,6 +734,7 @@ After the 'ee' message pattern (and before the 'ss' message pattern for IK), add
{% highlight lang='text' %} {% highlight lang='text' %}
This is the "ekem1" message pattern: This is the "ekem1" message pattern:
// DecryptAndHash(kem_ciphertext_section)
// AEAD parameters // AEAD parameters
k = keydata[32:63] k = keydata[32:63]
n = 0 n = 0
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment