diff options
| author | miod <> | 2014-11-18 05:33:43 +0000 |
|---|---|---|
| committer | miod <> | 2014-11-18 05:33:43 +0000 |
| commit | 262abb9ff4e2d2ca7a3d97ba9509d716fe37985d (patch) | |
| tree | 1ff6097d67d8f3a7af1e40761e736566bcd71b7d /src/lib/libssl/t1_enc.c | |
| parent | 0690f68b8ace3f1616822e1b9dbf5656beaaea16 (diff) | |
| download | openbsd-262abb9ff4e2d2ca7a3d97ba9509d716fe37985d.tar.gz openbsd-262abb9ff4e2d2ca7a3d97ba9509d716fe37985d.tar.bz2 openbsd-262abb9ff4e2d2ca7a3d97ba9509d716fe37985d.zip | |
Update the GOST code in libssl, as contributed by Dmitry Eremin-Solenikov.
This causes a libssl major version bump as this affects the layout of some
internal-but-unfortunately-made-visible structs.
Diffstat (limited to '')
| -rw-r--r-- | src/lib/libssl/t1_enc.c | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/src/lib/libssl/t1_enc.c b/src/lib/libssl/t1_enc.c index fc313efc2c..620da6ddd0 100644 --- a/src/lib/libssl/t1_enc.c +++ b/src/lib/libssl/t1_enc.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: t1_enc.c,v 1.72 2014/11/16 14:12:47 jsing Exp $ */ | 1 | /* $OpenBSD: t1_enc.c,v 1.73 2014/11/18 05:33:43 miod Exp $ */ |
| 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
| 3 | * All rights reserved. | 3 | * All rights reserved. |
| 4 | * | 4 | * |
| @@ -448,6 +448,18 @@ tls1_change_cipher_state_cipher(SSL *s, char is_read, char use_client_keys, | |||
| 448 | mac_secret_size, (unsigned char *)mac_secret); | 448 | mac_secret_size, (unsigned char *)mac_secret); |
| 449 | } | 449 | } |
| 450 | 450 | ||
| 451 | if (s->s3->tmp.new_cipher->algorithm_enc == SSL_eGOST2814789CNT) { | ||
| 452 | int nid; | ||
| 453 | if (s->s3->tmp.new_cipher->algorithm2 & SSL_HANDSHAKE_MAC_GOST94) | ||
| 454 | nid = NID_id_Gost28147_89_CryptoPro_A_ParamSet; | ||
| 455 | else | ||
| 456 | nid = NID_id_tc26_gost_28147_param_Z; | ||
| 457 | |||
| 458 | EVP_CIPHER_CTX_ctrl(cipher_ctx, EVP_CTRL_GOST_SET_SBOX, nid, 0); | ||
| 459 | if (s->s3->tmp.new_cipher->algorithm_mac == SSL_GOST89MAC) | ||
| 460 | EVP_MD_CTX_ctrl(mac_ctx, EVP_MD_CTRL_GOST_SET_SBOX, nid, 0); | ||
| 461 | } | ||
| 462 | |||
| 451 | return (1); | 463 | return (1); |
| 452 | 464 | ||
| 453 | err: | 465 | err: |
