summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNiels Möller <nisse@lysator.liu.se>2022-02-19 19:54:34 +0100
committerNiels Möller <nisse@lysator.liu.se>2022-02-19 19:54:34 +0100
commitbdc2fc317ba265f6eb584ad19e98a5bbaf1c39b9 (patch)
tree09aa365d760e72d3571469d6c958cf7c70e33862
parent1d438ad40aa983cf9dc3c0f41cabb6bea70af977 (diff)
downloadnettle-bdc2fc317ba265f6eb584ad19e98a5bbaf1c39b9.tar.gz
Move _ghash_digest.
-rw-r--r--ChangeLog5
-rw-r--r--ghash-set-key.c6
-rw-r--r--ghash-update.c6
3 files changed, 11 insertions, 6 deletions
diff --git a/ChangeLog b/ChangeLog
index edfd411a..dc288dd1 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2022-02-19 Niels Möller <nisse@lysator.liu.se>
+
+ * ghash-set-key.c (_ghash_digest): Moved function from...
+ * ghash-update.c (_ghash_digest): ...old location.
+
2022-02-18 Niels Möller <nisse@lysator.liu.se>
* block-internal.h (block16_zero): New function.
diff --git a/ghash-set-key.c b/ghash-set-key.c
index e8813a5e..fa3c5588 100644
--- a/ghash-set-key.c
+++ b/ghash-set-key.c
@@ -66,3 +66,9 @@ _ghash_set_key (struct gcm_key *ctx, const union nettle_block16 *key)
block16_xor3 (&ctx->h[i+j], &ctx->h[i], &ctx->h[j]);
}
}
+
+void
+_ghash_digest (const union nettle_block16 *state, union nettle_block16 *digest)
+{
+ block16_xor (digest, state);
+}
diff --git a/ghash-update.c b/ghash-update.c
index 00940ae5..b960bcda 100644
--- a/ghash-update.c
+++ b/ghash-update.c
@@ -136,9 +136,3 @@ _ghash_update (const struct gcm_key *ctx, union nettle_block16 *state,
}
return data;
}
-
-void
-_ghash_digest (const union nettle_block16 *state, union nettle_block16 *digest)
-{
- block16_xor (digest, state);
-}