Next: External commands: ( Up: Cryptographic module for digital Previous: Waiting for ...

Hardware

Consists of RAM 128 x 8 x 24 bits organised as register file and ALU. ALU can multiply four 16 bit integers moduli F4 in 2 cycles what takes about 100 Ns. When using ALU for larger number modular calculations it can be configured to act as one 1536 bit adder/subtractor. Modular calculations are further accelerated using smart compare functions. While IDEA will be built-in, discrete exponent based cryptosystems can be implemented using ALU programming language what among usual call-jump instructions has specific commands like DEXP (discrete exponent ). So it is rather easy to implement RSA or Diffie-Hellman key exchange protocol with just a few dozens commands. CC also contains random number generator based on physical random events and possibility to run IDEA at lower speeds if required encryption rate is lower than 10 Mbit/sec. This is useful for mobile equipment where power saving is of great importance. Programs that control ALU can be activated externally with External commands and on the first silicon run can be reconfigured. For security reasons on next silicon runs we will burn the algorithm into ROM and allow no user interception with that As an example of ALU programming style the following program calculates modular inverse


; A0L, A0H etc are half-sized registers  
; 768 bits wide.
; Modular Inverse
; input:    
;       A0L   element x
;       A0H   module  j
; output
;       A2H   1, if x is invertible
;             0  else
;       A1H   GCD(a,j) if A2H=0
;       A3L   x\^-1 if A2H=1
; ---------------------------------------------------------------
; variables 
;       A0L   x
;       A0H   j
;       A1L   a
;       A1H   m
;       A2L   k
;       A2H   e
;       A3L   u
;       A3H   b
; ------------------------------------------------------------------
inverse:        
        MVI   A4H, 1         ;
        MOV   A1H, A0H       ; m :=  j
        MVI   A3L, 1         ; u := 1
        MVI   A3H, 0         ; b := 0
        MOV   A2H, A0L       ; e := x
ndiv:                        ; repeat
        DIV   A1H, A2H, A2L  ;    k := [m/e]
        MOV   A1L, A3L       ;    a := u
        MUL   A2L, A3L, A3L  ;   
        ADD   A3H, A3L, A3L  ;    u := b + k*u         
        MOV   A3H, A1L       ;    b := a 
        MOV   A1L, A2H       ;    a := e
        MOD   A2H, A2H, A2H  ;    e := m mod e
        MOV   A2H, A1L       ;    m := a 
        JLT   A4H, A2H, ndiv ; until e<=1
        DMUL  A0L, A2L, A4H  ;
        ADI   A4H,  -1       ;
        JZ    A4H, inv\_ok   ; if (( x * u  mod j ) != 1 )  
        SUB   A0H, A3L, A3L  ;    u := j-u
inv\_ok:     
        RET

CC will have no built-in protocol handler, you must provide some external logic to feed it with necessary data.


www@pld.ttu.ee