diff --git a/prototype.lisp b/prototype.lisp index 5190803..1c28969 100644 --- a/prototype.lisp +++ b/prototype.lisp @@ -132,7 +132,7 @@ (if (null bf) (fold salt (cdr path) bf-prime) (fold salt (cdr path) (BL-Combine-Blinding-Factors bf bf-prime))))) - (t (multiple-value-bind (pk sk) (KEM-Derive-Key-Pair salt) + (t (multiple-value-bind (sk pk) (KEM-Derive-Key-Pair salt) (declare (ignore pk)) (fold (KEM-Decap (car path) sk) (cdr path) bf))))) @@ -155,7 +155,7 @@ (defun delegate-key-creation (app hdk) (KEM-Derive-Key-Pair (nth-value 1 (fold (seed app) hdk)))) (defun accept-key (app hdk kh index pk-expected) - (multiple-value-bind (pk sk) (delegate-key-creation app hdk) + (multiple-value-bind (sk pk) (delegate-key-creation app hdk) (declare (ignore pk)) (let ((salt (KEM-Decap kh sk)) (pk-bl (get-key-info app hdk))) @@ -178,7 +178,7 @@ (defun prove-possession (unit doc reader-data) (create-shared-secret (app unit) (unit-hdk unit doc) reader-data)) (defun request (unit doc-parent) - (delegate-key-creation (app unit) (unit-hdk unit doc-parent))) + (nth-value 1 (delegate-key-creation (app unit) (unit-hdk unit doc-parent)))) (defun accept (unit doc-parent kh index doc) (let* ((hdk (unit-hdk unit doc-parent)) (app (app unit))) @@ -232,7 +232,7 @@ (let* ((app (make-app)) (pk-bl (get-key-info app +hdk-root+)) - (pk-kem (delegate-key-creation app +hdk-root+))) + (pk-kem (nth-value 1 (delegate-key-creation app +hdk-root+)))) (multiple-value-bind (salt kh) (KEM-Encap pk-kem) (let ((pk-expected (BL-Blind-Public-Key pk-bl (HDK salt 0)))) (accept-key app +hdk-root+ kh 0 pk-expected))))