Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add signing methods for pre-determined nonces #24

Merged

Conversation

stringhandler
Copy link
Contributor

In some cases, the public nonce used in the signature is committed and
used in the challenge. These extra methods allow signing with a private
nonce to accommodate that. There is also support for signing a pre-hashed
byte array instead of a string message

CjS77
CjS77 previously approved these changes Nov 23, 2020
Copy link
Contributor

@CjS77 CjS77 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks ok, but one docstring typo.

/// key and a specified private nonce. DO NOT reuse nonces. This method is provide for cases where a
/// public nonce has been used
/// in the message.
#[wasm_bindgen]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you meant pre-hashed message, but can you explain what "hashed using the given private key" means? You usually hash with a hashing algorithm.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah needs a comma or something. PHRASING.

Generate a Schnorr signature of a challenge (that has already been hashed) using the given private

In some cases, the public nonce used in the signature is committed and
used in the challenge. These extra methods allow signing with a private
nonce to accommodate that. There is also support for signing a pre-hashed
byte array instead of a string message
@stringhandler stringhandler merged commit 981ba66 into tari-project:main Nov 24, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants