X-Git-Url: https://git.cryptolib.org/?a=blobdiff_plain;f=seed.c;h=29cd9913a11838749c898773f58d4a0790135ee0;hb=dd02da3bd4b9c9a84f68150b5cba987b73fd29af;hp=da240bdbbaaadbdf5964df91f84bc5d26ed10494;hpb=96ebafd201c9e8441c7677577b24aa402c1defc6;p=avr-crypto-lib.git diff --git a/seed.c b/seed.c index da240bd..29cd991 100644 --- a/seed.c +++ b/seed.c @@ -220,7 +220,7 @@ typedef struct{ /******************************************************************************/ -void seed_init(seed_ctx_t * ctx, uint8_t * key){ +void seed_init(uint8_t * key, seed_ctx_t * ctx){ memcpy(ctx->k, key, 128/8); } @@ -229,7 +229,7 @@ void seed_init(seed_ctx_t * ctx, uint8_t * key){ #define L (((uint64_t*)buffer)[0]) #define R (((uint64_t*)buffer)[1]) -void seed_encrypt(seed_ctx_t * ctx, void * buffer){ +void seed_encrypt(void * buffer, seed_ctx_t * ctx){ uint8_t r; keypair_t k; for(r=0; r<8; ++r){ @@ -262,7 +262,7 @@ void seed_encrypt(seed_ctx_t * ctx, void * buffer){ #define L (((uint64_t*)buffer)[0]) #define R (((uint64_t*)buffer)[1]) -void seed_decrypt(seed_ctx_t * ctx, void * buffer){ +void seed_decrypt(void * buffer, seed_ctx_t * ctx){ int8_t r; keypair_t k; for(r=7; r>=0; --r){