X-Git-Url: https://git.cryptolib.org/?a=blobdiff_plain;f=grain%2Fgrain.c;h=fc86ebfc8d17bb73cdbe460abb9dff3ab2992f03;hb=1f6be6ce98d01772fbb1f4d5205a13bea896a1f1;hp=ff6b97de41b46b689c211635d0d9613d557bca36;hpb=701cee0d98aab48dd3192c8cc7c77eb42581bc56;p=avr-crypto-lib.git diff --git a/grain/grain.c b/grain/grain.c index ff6b97d..fc86ebf 100644 --- a/grain/grain.c +++ b/grain/grain.c @@ -1,7 +1,7 @@ /* grain.c */ /* This file is part of the AVR-Crypto-Lib. - Copyright (C) 2008 Daniel Otte (daniel.otte@rub.de) + Copyright (C) 2006-2015 Daniel Otte (bg@nerilex.org) This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -19,7 +19,7 @@ /** * * author: Daniel Otte - * email: daniel.otte@rub.de + * email: bg@nerilex.org * license: GPLv3 or later * */ @@ -54,7 +54,7 @@ const uint8_t g_lut[128] PROGMEM = { 0xF3, 0x2E, 0xF3, 0x2E, 0x0C, 0xD1, 0x0C, 0x2E, 0xAC, 0x71, 0xAC, 0x71, 0x53, 0x71, 0xA3, 0xD4 }; #endif -uint8_t grain_enc(grain_ctx_t* ctx){ +uint8_t grain_enc(grain_ctx_t *ctx){ uint8_t s80, s0, c1, c2; uint8_t i; /* clock the LFSR */ @@ -137,7 +137,7 @@ uint8_t grain_enc(grain_ctx_t* ctx){ return (h&1); } -uint8_t grain_getbyte(grain_ctx_t* ctx){ +uint8_t grain_getbyte(grain_ctx_t *ctx){ uint8_t i=0; uint8_t r=0; do{ @@ -166,7 +166,7 @@ uint8_t reverse_bits(uint8_t a){ #endif -void grain_init(const void* key, const void* iv, grain_ctx_t* ctx){ +void grain_init(const void *key, const void *iv, grain_ctx_t *ctx){ uint8_t i,t; /* load the 80bit key */