X-Git-Url: https://git.cryptolib.org/?a=blobdiff_plain;f=mqq-sign%2Fmqq160-sign.c;h=99c4db8e46c2fba5cee76ae5aa6e8dc08af58707;hb=701cee0d98aab48dd3192c8cc7c77eb42581bc56;hp=2843f7b77f34c5f0827ac7466fc6be26636aeec7;hpb=056b130e8185a29017a3f3feb0b7db4e84080b09;p=avr-crypto-lib.git diff --git a/mqq-sign/mqq160-sign.c b/mqq-sign/mqq160-sign.c index 2843f7b..99c4db8 100644 --- a/mqq-sign/mqq160-sign.c +++ b/mqq-sign/mqq160-sign.c @@ -23,7 +23,7 @@ #include "cli.h" -static uint8_t mod20_table[32] PROGMEM = { +static const uint8_t mod20_table[32] PROGMEM = { 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 0, 1, 2, 3, 4, 5, 6, 7, @@ -46,7 +46,7 @@ in the MQQ160-SIGN C Library. static void mqq_inv_affine_transformation(const uint8_t* input_bytes, uint8_t* result, const mqq160_sign_key_t* key){ /* The matrix SInv is given as two permutations of 160 elements. */ uint8_t j, byteindex, bitindex, bitindex_d, byteindex_d, rp1, rp5; - uint8_t *rp1_ptr, *rp5_ptr; + const uint8_t *rp1_ptr, *rp5_ptr; uint8_t h1[20]; @@ -100,7 +100,7 @@ static uint8_t mqq_q(uint8_t i, uint8_t b1, uint8_t b2, const mqq160_sign_key_t* uint8_t result, column, row, k; int8_t j; uint16_t temp; - uint8_t *tmp_ptr=key->a; + const uint8_t *tmp_ptr=key->a; if(i&1){ memcpy(e, key->cc1, 9); while(b1){