bls-signatures icon indicating copy to clipboard operation
bls-signatures copied to clipboard

Division operator for GTElement (e1/e2)

Open lokingdav opened this issue 2 years ago • 8 comments

Currently creating a witness encryption scheme based on BLS signatures. I am using this library. However, I needed the GTElement class to support inversing through divisions. Instead of reimplementing element classes (since r is private in GT), this PR fixed the issue.

I know BLS signature implementation does not use division, but libraries that depend on this might need it. Moreover, my witness encryption library currently depends on my fork, and I want to use the main Chia-Network/bls-signatures instead.

lokingdav avatar Oct 25 '23 18:10 lokingdav

Pull Request Test Coverage Report for Build 6819261096

Warning: This coverage report may be inaccurate.

We've detected an issue with your CI configuration that might affect the accuracy of this pull request's coverage report. To ensure accuracy in future PRs, please see these guidelines. A quick fix for this PR: rebase it; your next report should be accurate.

  • 9 of 9 (100.0%) changed or added relevant lines in 2 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.03%) to 94.677%

Totals Coverage Status
Change from base Build 6614779237: 0.03%
Covered Lines: 1654
Relevant Lines: 1747

💛 - Coveralls

coveralls-official[bot] avatar Oct 25 '23 18:10 coveralls-official[bot]

Can you sign your commit?

hoffmang9 avatar Nov 07 '23 22:11 hoffmang9

image Looks like something is still a bit off.

hoffmang9 avatar Nov 10 '23 01:11 hoffmang9

image Looks like something is still a bit off.

Yeah i noticed and I'm resolving it. Used a different email for this repository

lokingdav avatar Nov 10 '23 01:11 lokingdav

'This PR has been flagged as stale due to no activity for over 60 days. It will not be automatically closed, but it has been given a stale-pr label and should be manually reviewed.'

github-actions[bot] avatar Jan 09 '24 11:01 github-actions[bot]

Apologies for the long delay in looking at this. But I have a question. The included test is odd since division is not normally commutative - so one doesn't expect a test where a/b == b/a

I would expect something like (a*b)/b == a - does this version of division pass that test?

Reading a little more carefully, I see gt1 and gt2 are actually the same element - the test is then a/a == a/a which doesn't seem very useful?

emlowe avatar May 13 '24 22:05 emlowe

Hi @emlowe thanks for this message. In fact, I forgot about this PR.

Your observation is correct, which would be a more precise test. The current test works because gt1 and gt2 are both GT generators and are the same. It will make more sense that gt1 and gt2 are different elements. I'll update the test.

lokingdav avatar May 16 '24 00:05 lokingdav

'This PR has been flagged as stale due to no activity for over 60 days. It will not be automatically closed, but it has been given a stale-pr label and should be manually reviewed.'

github-actions[bot] avatar Jul 15 '24 11:07 github-actions[bot]