by Sanjay S B
Last Updated October 09, 2019 12:28 PM - source

I am trying to verify an RSA signature using Ethereum smart contract. I have some doubts regarding my design.

I am using the precompile at address 0X05 to generate `s^e mod n`

, where s is the signature to be verified, e is the exponent used during key generation. n is the public Key. I understand that I have to provide s, e and n as uint256.

I will compare the value obtained as output from precompile to compare with the original message's hex. Is this the right way?

I am able to get e as a number in JavaScript but s and n I have are buffers. how do I convert them to integer to use in the smart contract invocation?

- Serverfault Help
- Superuser Help
- Ubuntu Help
- Webapps Help
- Webmasters Help
- Programmers Help
- Dba Help
- Drupal Help
- Wordpress Help
- Magento Help
- Joomla Help
- Android Help
- Apple Help
- Game Help
- Gaming Help
- Blender Help
- Ux Help
- Cooking Help
- Photo Help
- Stats Help
- Math Help
- Diy Help
- Gis Help
- Tex Help
- Meta Help
- Electronics Help
- Stackoverflow Help
- Bitcoin Help
- Ethereum Help