~mdw
/
catacomb
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
progs/perftest.c: Use from Glibc syscall numbers.
[catacomb]
/
symm
/
gcm-def.h
diff --git
a/symm/gcm-def.h
b/symm/gcm-def.h
index
6ca5895
..
ffa008c
100644
(file)
--- a/
symm/gcm-def.h
+++ b/
symm/gcm-def.h
@@
-392,9
+392,9
@@
int pre##_gcmencrypt(pre##_gcmctx *ctx, \
/* Determine the buffering plan. Our buffer is going to do double- \
* duty here. The end portion is going to contain mask from the \
* encrypted counter which we mix into the plaintext to encrypt it; \
/* Determine the buffering plan. Our buffer is going to do double- \
* duty here. The end portion is going to contain mask from the \
* encrypted counter which we mix into the plaintext to encrypt it; \
- * the start portion, which originally
mask bytes we've already used,
\
- *
will hold the output ciphertext, which will eventually be
\
- *
collected into the GHASH state.
\
+ * the start portion, which originally
contained mask bytes we've
\
+ *
already used, will hold the output ciphertext, which will
\
+ *
eventually be collected into the GHASH state.
\
*/ \
rsvr_mkplan(&plan, &pre##_gcmpolicy, ctx->off, sz); \
\
*/ \
rsvr_mkplan(&plan, &pre##_gcmpolicy, ctx->off, sz); \
\
@@
-477,9
+477,9
@@
int pre##_gcmdecrypt(pre##_gcmctx *ctx, \
/* Determine the buffering plan. Our buffer is going to do double- \
* duty here. The end portion is going to contain mask from the \
* encrypted counter which we mix into the plaintext to encrypt it; \
/* Determine the buffering plan. Our buffer is going to do double- \
* duty here. The end portion is going to contain mask from the \
* encrypted counter which we mix into the plaintext to encrypt it; \
- * the start portion, which originally
mask bytes we've already used,
\
- *
will hold the input ciphertext, which will eventually be
\
- *
collected into the GHASH state.
\
+ * the start portion, which originally
contained mask bytes we've
\
+ *
already used, will hold the input ciphertext, which will
\
+ *
eventually be collected into the GHASH state.
\
*/ \
rsvr_mkplan(&plan, &pre##_gcmpolicy, ctx->off, sz); \
\
*/ \
rsvr_mkplan(&plan, &pre##_gcmpolicy, ctx->off, sz); \
\
@@
-790,11
+790,14
@@
static gaead_key *gckey(const void *k, size_t ksz) \
return (&key->k); \
} \
\
return (&key->k); \
} \
\
+static int gcszok(size_t nsz, size_t hsz, size_t msz, size_t tsz) \
+ { return (gaead_szokcommon(&pre##_gcm, nsz, hsz, msz, tsz)); } \
+ \
const gcaead pre##_gcm = { \
name "-gcm", \
pre##_keysz, pre##_gcmnoncesz, pre##_gcmtagsz, \
PRE##_BLKSZ, 0, 0, 0, \
const gcaead pre##_gcm = { \
name "-gcm", \
pre##_keysz, pre##_gcmnoncesz, pre##_gcmtagsz, \
PRE##_BLKSZ, 0, 0, 0, \
- gckey
\
+ gckey
, gcszok
\
}; \
\
GCM_TESTX(PRE, pre, name, fname)
}; \
\
GCM_TESTX(PRE, pre, name, fname)