After another week I managed to force the module to work (correctly!). I had a really hard time debugging it, since you can’t simply expect to find a mistake by looking at seemingly random combinations of 163bits. I was forced to run again and again through the whole code and “simulate” it’s behaviour on a sheet of paper, but eventually it paid off. There were of course a lot of stupid mistakes as well, like typical programming one to run a loop one too many/less time.

Unfortunately, this time, Dear Reader, I don’t have any screenshots to share. I will try to upload some later, however the problem is that in order to verify them You would have to run  appropriate test vectors through some trusted 3rd party software and compare with my results.

The special thing about this module is it’s simplicity to use. It can work in two modes which I call “single point” and “double point”. Anyone who is familiar with ECDSA knows that a crucial part is the scalar point multiplication operation but it is slightly different for signing and veryfication procedures. One needs to calculate coordinates of the point k*P and u1*G + u2*Q respectively (thus single and double point mode). In most solutions to perform the later, one first sends u1 and G to the module, stores the result, sends the second part, stores the result and then sends both points u1*G and u2*Q to perform one addition. Our solution needs only one configuration write where the requested mode is specified followed by 5 or 8 bit strings (a,b coefficients of the curve, scalar to multiply by, x,y coordinates of the point and optionally another scalar and set of coordinates) and as an output module returns only the final result.

Another important thing about the module is it’s compact size. Initial synthesis showed only 2200 LUTs and 1200 slice registers which is very little compared with other solutions, however those numbers may change yet. Depending on available resources, field multiplier which is the main bottleneck could be upgraded (increased size for faster operation).

Stay tuned as there will be more info from Radek-ECDSA front.

Categories: Experiential


Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.