[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lsd0001] branch master updated: comments in pseudocode
From: |
gnunet |
Subject: |
[lsd0001] branch master updated: comments in pseudocode |
Date: |
Wed, 09 Feb 2022 14:02:51 +0100 |
This is an automated email from the git hooks/post-receive script.
martin-schanzenbach pushed a commit to branch master
in repository lsd0001.
The following commit(s) were added to refs/heads/master by this push:
new 4e4fb35 comments in pseudocode
4e4fb35 is described below
commit 4e4fb3536aeda118ed2c5b8632d36bc4ae0b7be0
Author: Martin Schanzenbach <schanzen@gnunet.org>
AuthorDate: Wed Feb 9 14:02:47 2022 +0100
comments in pseudocode
---
draft-schanzen-gns.xml | 12 +++++++++++-
1 file changed, 11 insertions(+), 1 deletion(-)
diff --git a/draft-schanzen-gns.xml b/draft-schanzen-gns.xml
index 64abd62..a05af98 100644
--- a/draft-schanzen-gns.xml
+++ b/draft-schanzen-gns.xml
@@ -1167,14 +1167,20 @@ S-Decrypt(zk,label,expiration,ciphertext):
</t>
<artwork name="" type="" align="left" alt=""><![CDATA[
ZKDF-Private(d,label):
+ /* Calculate zk from d */
a := SHA-512 (d)
+ /* EdDSA clamping */
a[0] &= 248
a[31] &= 127
a[31] |= 64
zk := a * G
+
+ /* Calculate the blinding factor */
PRK_h := HKDF-Extract ("key-derivation", zk)
h := HKDF-Expand (PRK_h, label || "gns", 512 / 8)
+ /* Ensure that h == h mod L */
h[31] &= 7
+
a1 := a >> 3
a2 := (h * a1) mod L
d' := a2 << 3
@@ -1186,9 +1192,12 @@ ZKDF-Private(d,label):
</t>
<artwork name="" type="" align="left" alt=""><![CDATA[
ZKDF-Public(zk,label):
+ /* Calculate the blinding factor */
PRK_h := HKDF-Extract ("key-derivation", zk)
h := HKDF-Expand (PRK_h, label || "gns", 512 / 8)
+ /* Ensure that h == h mod L */
h[31] &= 7
+
zk' := h * zk
return zk'
]]></artwork>
@@ -1244,8 +1253,9 @@ ZKDF-Public(zk,label):
</t>
<artwork name="" type="" align="left" alt=""><![CDATA[
SignDerived(d,label,message):
- /* Calculate public key */
+ /* Calculate zk from d */
a := SHA-512 (d)
+ /* EdDSA clamping */
a[0] &= 248
a[31] &= 127
a[31] |= 64
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [lsd0001] branch master updated: comments in pseudocode,
gnunet <=