From e084d3475e3858ea9f5a8ccfa63a08de2db79181 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Niels=20M=C3=B6ller?= <nisse@lysator.liu.se> Date: Mon, 8 Oct 2001 22:57:34 +0200 Subject: [PATCH] * yarrow.h (struct yarrow_key_event_ctx): New struct. Rev: src/nettle/ChangeLog:1.36 Rev: src/nettle/yarrow.h:1.5 --- ChangeLog | 2 ++ yarrow.h | 15 +++++++++++++++ 2 files changed, 17 insertions(+) diff --git a/ChangeLog b/ChangeLog index f21958d1..b634e6f9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,7 @@ 2001-10-08 Niels M�ller <nisse@cuckoo.hack.org> + * yarrow.h (struct yarrow_key_event_ctx): New struct. + * yarrow256.c (yarrow_fast_reseed): Generate two block of output using the old key and feed into the pool. diff --git a/yarrow.h b/yarrow.h index 464f9947..1f4fec97 100644 --- a/yarrow.h +++ b/yarrow.h @@ -103,5 +103,20 @@ yarrow256_random(struct yarrow256_ctx *ctx, unsigned length, uint8_t *dst); int yarrow256_seeded(struct yarrow256_ctx *ctx); +/* Key event estimator */ +struct yarrow_key_event_ctx +{ + /* Counter for initial priming of the state */ + unsigned index; + unsigned chars[16]; + unsigned previous; +}; +void +yarrow_key_event_init(struct yarrow_key_event_ctx *ctx); + +unsigned +yarrow_key_event_estimate(struct yarrow_key_event_ctx *ctx, + unsigned key, unsigned time); + #endif /* NETTLE_YARROW_COMPAT_H_INCLUDED */ -- GitLab