elliptic-curves icon indicating copy to clipboard operation
elliptic-curves copied to clipboard

`Curve448` with full coordinates

Open daxpedda opened this issue 7 months ago • 2 comments

This PR implements a set of types for Montgomery points with a full coordinate system and corresponding Curve448 type with a CurveArithmetic implementation. Our current MontgomeryPoint x-coordinate only remains in place for use with X448 and is renamed to MontgomeryXpoint.

For context: the x-only coordinate system can't implement a full set of arithmetic operations because of the missing y-coordinate. While the y-coordinate could be recovered, it is costly and is missing the sign. Some protocols exist that set the sign of the y-coordinate, which is why we have some methods in place for MontgomeryXpoint to do exactly that.

I made sure to add a full set of conversion methods between the new types.

I'm aware that I'm proposing very large changes that have not previously been discussed. I'm happy to take any feedback. It should be much easier to review than #1291 on account that it can be done commit by commit.

Take 2 on #1291.

daxpedda avatar Jul 19 '25 00:07 daxpedda

Do you have any protocol in mind where this would be used?

carloskiki avatar Jul 20 '25 14:07 carloskiki

Yes, I am planning on using it with OPRF inside OPAQUE.

daxpedda avatar Jul 20 '25 14:07 daxpedda