diff options
author | Darren Tucker <dtucker@dtucker.net> | 2019-07-23 21:51:22 +1000 |
---|---|---|
committer | Darren Tucker <dtucker@dtucker.net> | 2019-07-23 22:06:24 +1000 |
commit | 11cba2a4523fda447e2554ea457484655bedc831 (patch) | |
tree | 93ec07a9e0db784b0a729eb339d74a5a2c40ea9d /mac.c | |
parent | 09159594a3bbd363429ee6fafde57ce77986dd7c (diff) |
Re-apply portability changes to current sha2.{c,h}.
Rather than attempt to apply 14 years' worth of changes to OpenBSD's sha2
I imported the current versions directly then re-applied the portability
changes. This also allowed re-syncing digest-libc.c against upstream.
Diffstat (limited to 'mac.c')
-rw-r--r-- | mac.c | 4 |
1 files changed, 0 insertions, 4 deletions
@@ -58,10 +58,8 @@ static const struct macalg macs[] = { | |||
58 | /* Encrypt-and-MAC (encrypt-and-authenticate) variants */ | 58 | /* Encrypt-and-MAC (encrypt-and-authenticate) variants */ |
59 | { "hmac-sha1", SSH_DIGEST, SSH_DIGEST_SHA1, 0, 0, 0, 0 }, | 59 | { "hmac-sha1", SSH_DIGEST, SSH_DIGEST_SHA1, 0, 0, 0, 0 }, |
60 | { "hmac-sha1-96", SSH_DIGEST, SSH_DIGEST_SHA1, 96, 0, 0, 0 }, | 60 | { "hmac-sha1-96", SSH_DIGEST, SSH_DIGEST_SHA1, 96, 0, 0, 0 }, |
61 | #ifdef HAVE_EVP_SHA256 | ||
62 | { "hmac-sha2-256", SSH_DIGEST, SSH_DIGEST_SHA256, 0, 0, 0, 0 }, | 61 | { "hmac-sha2-256", SSH_DIGEST, SSH_DIGEST_SHA256, 0, 0, 0, 0 }, |
63 | { "hmac-sha2-512", SSH_DIGEST, SSH_DIGEST_SHA512, 0, 0, 0, 0 }, | 62 | { "hmac-sha2-512", SSH_DIGEST, SSH_DIGEST_SHA512, 0, 0, 0, 0 }, |
64 | #endif | ||
65 | { "hmac-md5", SSH_DIGEST, SSH_DIGEST_MD5, 0, 0, 0, 0 }, | 63 | { "hmac-md5", SSH_DIGEST, SSH_DIGEST_MD5, 0, 0, 0, 0 }, |
66 | { "hmac-md5-96", SSH_DIGEST, SSH_DIGEST_MD5, 96, 0, 0, 0 }, | 64 | { "hmac-md5-96", SSH_DIGEST, SSH_DIGEST_MD5, 96, 0, 0, 0 }, |
67 | { "umac-64@openssh.com", SSH_UMAC, 0, 0, 128, 64, 0 }, | 65 | { "umac-64@openssh.com", SSH_UMAC, 0, 0, 128, 64, 0 }, |
@@ -70,10 +68,8 @@ static const struct macalg macs[] = { | |||
70 | /* Encrypt-then-MAC variants */ | 68 | /* Encrypt-then-MAC variants */ |
71 | { "hmac-sha1-etm@openssh.com", SSH_DIGEST, SSH_DIGEST_SHA1, 0, 0, 0, 1 }, | 69 | { "hmac-sha1-etm@openssh.com", SSH_DIGEST, SSH_DIGEST_SHA1, 0, 0, 0, 1 }, |
72 | { "hmac-sha1-96-etm@openssh.com", SSH_DIGEST, SSH_DIGEST_SHA1, 96, 0, 0, 1 }, | 70 | { "hmac-sha1-96-etm@openssh.com", SSH_DIGEST, SSH_DIGEST_SHA1, 96, 0, 0, 1 }, |
73 | #ifdef HAVE_EVP_SHA256 | ||
74 | { "hmac-sha2-256-etm@openssh.com", SSH_DIGEST, SSH_DIGEST_SHA256, 0, 0, 0, 1 }, | 71 | { "hmac-sha2-256-etm@openssh.com", SSH_DIGEST, SSH_DIGEST_SHA256, 0, 0, 0, 1 }, |
75 | { "hmac-sha2-512-etm@openssh.com", SSH_DIGEST, SSH_DIGEST_SHA512, 0, 0, 0, 1 }, | 72 | { "hmac-sha2-512-etm@openssh.com", SSH_DIGEST, SSH_DIGEST_SHA512, 0, 0, 0, 1 }, |
76 | #endif | ||
77 | { "hmac-md5-etm@openssh.com", SSH_DIGEST, SSH_DIGEST_MD5, 0, 0, 0, 1 }, | 73 | { "hmac-md5-etm@openssh.com", SSH_DIGEST, SSH_DIGEST_MD5, 0, 0, 0, 1 }, |
78 | { "hmac-md5-96-etm@openssh.com", SSH_DIGEST, SSH_DIGEST_MD5, 96, 0, 0, 1 }, | 74 | { "hmac-md5-96-etm@openssh.com", SSH_DIGEST, SSH_DIGEST_MD5, 96, 0, 0, 1 }, |
79 | { "umac-64-etm@openssh.com", SSH_UMAC, 0, 0, 128, 64, 1 }, | 75 | { "umac-64-etm@openssh.com", SSH_UMAC, 0, 0, 128, 64, 1 }, |