Signature Scheme Implementation for nrf52 series

Dear customer support people,

I'm trying to employ a particular signature scheme to benchmark it against other more traditional methods on your devices, specifically on a nrf52840DK. Specifically, the signature scheme is BBS, a relatively new method that is gaining a lot of attention in the information security sector for many different reasons. Before me, I have two options: either implement it by myself using psa_crypto and mbed_tls or to use already defined libraries like the one available at libbbs. The main problem with this second option is that it has relic as a sole dependency. Considering that relic is a dependency for another library that I'd like to use on your devices in the near future, I'd like to follow the second path and try to implement it this way (assuming the flash memory is sufficiently large to permit this implementation.

Unfortunately, relic is a library built for modern operative systems like Linux or Windows, and I'm afraid that using external libraries like gmp could not be feasible in Zephyr (please correct me if I'm wrong). Considering that relic does require to be build through CMake, I would love to try to include it in the building process of an application for nrf52840. This being said, though, I know for a fact that relic does support the arm architecture.

I was wondering if you have any insights or any suggestions on how to approach this possibility (whether you're familiar with relic or not), I'd be really grateful for your help.

As an alternative, I would appreciate a lot any link to specific implementations of mbed_tls and how to employ ECC cryptography (and possibly pairing based cryptography) in the extreme possibility of implementing the signature scheme myself.

Thank you in advance,

Kind regards and a wish for a happy new year,

Alessandro

  • Hi Alessandro,

    I am not familiar with relic or libbbs so I do not have any specific input on that. It seems to me that it is purely software based though, so even if you port it successfully to the nRF you would not benefit from the CryptoCell CC310 crypto accelerator on the nRF52840.

    For using the crypto accelerator and for future-proofing for other nRF devices, I suggest you look at implementing it using PSA crypto APIs. There are several crytpo examples you may find relevant in the SDK, including ECC samples.

  • Hi Einar, thanks for your response!

    I'm familiar with the examples you provided: in fact, I've been using one of these to leverage high-level APIs to interact with security modules. Unfortunately, if I had to implement things myself I'd have to hack into the lower levels to employ the finite field arithmetic libraries employed by other signature schemes included in the crypto examples you provided. Do you have any suggestions about where could I find more about lower level libraries like mbed_tls? The official site doesn't really provide much information...

    Other than that, aside the familiarity with specific libraries, are you aware of any guide that could help me integrate libraries that need to be built with CMake (similarly to our projects) into the nrf Connect SDK environment?

    Thank you in advance,

    Alessandro

Related