aboutsummaryrefslogtree2016-05-21Add code to test reading, writing and erasing keystore data.Fredrik Thulin
2016-05-21Add code to access the keystore memory (SPI flash).Fredrik Thulin
2016-05-21Add some exciting defines to define commans in the CLI.Fredrik Thulin
2016-05-20Add code to reset FPGA using FPGA_PROGRAM_B and FPGA_INIT_B.Fredrik Thulin
2016-05-19Refactor FPGA bitstream upload code.Fredrik Thulin
2016-05-18Add FPGA bitstream upload command to cli-test.Fredrik Thulin
2016-05-18A little more robust file transferFredrik Thulin
2016-05-18put some generic CLI code in mgmt-cli.cFredrik Thulin
2016-05-18Add reboot command.Fredrik Thulin
2016-05-18Write in 4k-chunks, with acks for flow control.Fredrik Thulin
2016-05-18build libcliPaul Selkirk
2016-05-16Use baud rate 921600 instead of 115200.Fredrik Thulin
2016-05-15add simple filetransfer pocFredrik Thulin
2016-05-13Add test program for libcli based CLI.Fredrik Thulin
color: #2B2; background-color: #F0FFF0 } /* Literal.String.Other */ .highlight .sr { color: #080; background-color: #FFF0FF } /* Literal.String.Regex */ .highlight .s1 { color: #D20; background-color: #FFF0F0 } /* Literal.String.Single */ .highlight .ss { color: #A60; background-color: #FFF0F0 } /* Literal.String.Symbol */ .highlight .bp { color: #038 } /* Name.Builtin.Pseudo */ .highlight .fm { color: #06B; font-weight: bold } /* Name.Function.Magic */ .highlight .vc { color: #369 } /* Name.Variable.Class */ .highlight .vg { color: #D70 } /* Name.Variable.Global */ .highlight .vi { color: #33B } /* Name.Variable.Instance */ .highlight .vm { color: #369 } /* Name.Variable.Magic */ .highlight .il { color: #00D; font-weight: bold } /* Literal.Number.Integer.Long */

modexp

Modular exponentiation core for implementing public key algorithms such as RSA, DH, ElGamal etc.

The core calculates the following function:

C = M ** e mod N

M is a message with a length of n bits e is the exponent with a length of m bits N is the modulus with a length of n bits

The size n be one and up to and including 8192 bits in steps of 32 bits.

The size m be one and up to and including 8192 bits in steps of 32 bits.

The core has a 32-bit memory like interface, but provides status signals to inform the system that a given operation has is done. Additionally, any errors will also be asserted.

The core is written in Verilog 2001 and suitable for implementation in FPGA and ASIC devices. No vendor specific macros are used in the code.

Implementation details

The core is iterative with 32-bit operands and not the fastest core on the planet.

Future developments

FPGA-results

Altera Cyclone-V

Xilinx Artix-7 100T

Xilinx Spartan-6 LX45

Status

(2015-04-27)

Modexp simulation with exponent and modolus with up to 1280 bits simulates. The auto test generation system works. Implementation in different FPGA types and vendors works.

(2015-04-23)

The Montgomery multiplication module works. The Residue calculation module works. Top level integration and debugging is onging. The core does not yet work and there are dragons to be found.

(2014-12-07)

Renamed the core tom modexp from rsa to make it more clear that it provides generic modular exponentiation, not RSA.

(2014-10-01)

Very early phase. Started to collect information and drawing some rough ideas on paper.