LPC55S16 - Curiosity about Casper API

取消
显示结果 
搜索替代 
您的意思是: 

LPC55S16 - Curiosity about Casper API

804 次查看
can_pouliquen
Contributor II

Hello,

As I was exploring the API for CASPER (LPC55S16), I realized that the exponent and the modulus used for the modular exponentiation function weren't declared of the same size. Out of curiosity, why not declare both exponent and modulus as 8-bits ?

Again, out of simple curiosity, why solely provide a modexp oriented towards signature verification and not encryption ?

If you have any idea or answers, I would gladly welcome them !

Thank you in advance

Said function :

void CASPER_ModExp(CASPER_Type *base, const uint8_t *signature, const uint8_t *pubN, size_t wordLen, uint32_t pubE, uint8_t *plaintext);

标签 (4)
1 回复

755 次查看
Sabina_Bruce
NXP Employee
NXP Employee

Hello ,

Hope you are doing well.

To answer your questions:

1. Just to confirm the two variables that you are referring to are the following:

pastedImage_1.png

Is this correct?

If so, the variable that is passed for the first one is actually a pointer and the second one is getting the actual value of the variable. From the example you may see that it pubN is receiving the pointer(size of pointer is 8) for the pubkey0 containing a value which is actually 2048 bits long. The pubE is receiving the value pub_e of 0x10001.

2. For details as to the purpose of Casper and the objective in which modexp was implemented. I believe you will find this information in the following application note:

Asymmetric Cryptographic Accelerator CASPER 

Best Regards,

Sabina

-----------------------------------------------------------------------------------------------------------------------

Note: If this post answers your question, please click the Correct Answer button. Thank you!

-----------------------------------------------------------------------------------------------------------------------