X-Git-Url: https://git.distorted.org.uk/~mdw/catacomb/blobdiff_plain/0f00dc4c8eb47e67bc0f148c2dd109f73a451e0a..8f2287ef5c05d496fcb9b012629af007fe56f897:/symm/desx.c diff --git a/symm/desx.c b/symm/desx.c index d65ffa75..14115a57 100644 --- a/symm/desx.c +++ b/symm/desx.c @@ -38,12 +38,11 @@ #include "des-base.h" #include "des.h" #include "desx.h" -#include "desx-tab.h" #include "gcipher.h" /*----- Tables ------------------------------------------------------------*/ -static const octet s[256] = DESX_S; +extern const octet desx_s[256]; /*----- Global variables --------------------------------------------------*/ @@ -62,7 +61,7 @@ const octet desx_keysz[] = { KSZ_SET, 23, 7, 8, 15, 16, 24, 0 }; * Use: Initializes a DESX key buffer. The key buffer contains, in * order, a single-DES key (either 7 or 8 bytes), an optional * 8-byte pre-whitening key, and an optional 8-byte - * port-whitening key. If no whitening keys are specified, the + * post-whitening key. If no whitening keys are specified, the * algorithm becomes the same as single-DES. */ @@ -71,7 +70,7 @@ static void mangle(octet *b, const octet *p) unsigned i; for (i = 0; i < 8; i++) - b[i] = *p++ ^ s[b[i] ^ b[(i + 1) & 7u]]; + b[i] = *p++ ^ desx_s[b[i] ^ b[(i + 1) & 7u]]; } void desx_init(desx_ctx *k, const void *buf, size_t sz)