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

EllipticCurve_with_order() crashes with overflow error on values of 64 bits or more #38342

Closed
2 tasks done
JosePisco opened this issue Jul 9, 2024 · 0 comments · Fixed by #38341
Closed
2 tasks done

Comments

@JosePisco
Copy link
Contributor

Steps To Reproduce

Building sagemath from the source code on Ubuntu 22.04 and on version 10.4.beta8 (or any version after #37119 I suppose), run

sage: from sage.schemes.elliptic_curves.ell_finite_field import EllipticCurve_with_order
sage: N = randint(2^63, 2^64-1)
....: for E in EllipticCurve_with_order(N):
....:     print(E)
Traceback (most recent call last)
...
OverflowError: Python int too large to convert to C long

Expected Behavior

EllipticCurve_with_order() should handle big integers or precise that it doesn't in its docstring.

Actual Behavior

Feeding an integer of 64 bits or more to the function overflows with the error OverflowError: Python int too large to convert to C long.

Additional Information

No response

Environment

- **OS**: Ubuntu 22.04
- **Sage Version**: 10.4.beta8, Release Date: 2024-06-01, built from source code

Checklist

  • I have searched the existing issues for a bug report that matches the one I want to file, without success.
  • I have read the documentation and troubleshoot guide
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants