Skip to content

Conversation

lightsing
Copy link
Member

No description provided.

(false, false) => {
let mut p1 = secp256k1_mul(&AffinePoint::GENERATOR, u1);
let p2 = secp256k1_mul(&r_point, u2);
syscall_secp256k1_add(&mut p1, &p2);
Copy link
Collaborator

Choose a reason for hiding this comment

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

Hi @dreamATD could you helps to review the usage here, e.g.
do we need to check p1 != p2 before calling syscall_secp256k1_add ?

Besides, question from @lightsing: does it work for p1 or p2 to be infinite point? or we should handle it before syscall?

Copy link
Collaborator

@hero78119 hero78119 left a comment

Choose a reason for hiding this comment

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

Just one minor issue, other LGTM!


// FIXME: do we really need to verify the signature again here?
// Original:
// let vk = VerifyingKey::from_affine(pk.to_affine())?;
Copy link
Collaborator

Choose a reason for hiding this comment

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

per offline discussion, this operation seems to be the key to bind relation of (prehash, signature, recovery_id) so let retain original functionality

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.

2 participants