]> Git Repo - secp256k1.git/commit
Merge #741: Remove unnecessary sign variable from wnaf_const
authorTim Ruffing <[email protected]>
Sun, 26 Jul 2020 10:18:17 +0000 (12:18 +0200)
committerTim Ruffing <[email protected]>
Sun, 26 Jul 2020 10:21:14 +0000 (12:21 +0200)
commit3e5cfc5c73f856010fe646657703faf8d63e7120
tree8e9012e75ba4c7951ce3600f29f1519be431cada
parent66bb9320c0c000cf37165bd44c34ad4efc91a78c
parent37dba329c6cb0f7a4228a11dc26aa3a342a3a5d0
Merge #741: Remove unnecessary sign variable from wnaf_const

37dba329c6cb0f7a4228a11dc26aa3a342a3a5d0 Remove unnecessary sign variable from wnaf_const (Jonas Nick)
6bb0b77e158fc2f9e56e4b65b08bcb660d4c588b Fix test_constant_wnaf for -1 and add a test for it. (Jonas Nick)

Pull request description:

  There currently is a single branch in the `ecmul_const` function that is not being exercised by the tests. This branch is unreachable and therefore I'm suggesting to remove it.

  For your convenience the paper the wnaf algorithm can be found [here (The Width-w NAF Method Provides Small Memory and Fast Elliptic Scalar Multiplications Secure against Side Channel Attacks)](http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.563.1267&rep=rep1&type=pdf). Similarly, unless I'm missing something important, I don't see how their algorithm needs to consider `sign(u[i-1])` unless `d` can be negative - which doesn't make much sense to me either.

ACKs for top commit:
  real-or-random:
    ACK 37dba329c6cb0f7a4228a11dc26aa3a342a3a5d0 I verified the correctness of the change and claimed invariant by manual inspection. I tested the code, both with 32bit and 64bit scalars.

Tree-SHA512: 9db45f76bd881d00a81923b6d2ae1c3e0f49a82a5d55347f01e1ce4e924d9a3bf55483a0697f25039c327e33edca6796ba3205c068d9f2f99aa5d655e46b15be
src/ecmult_const_impl.h
src/tests.c
This page took 0.025164 seconds and 4 git commands to generate.