diff options
| author | jsing <> | 2021-10-25 10:01:46 +0000 |
|---|---|---|
| committer | jsing <> | 2021-10-25 10:01:46 +0000 |
| commit | 03322a1b7dc461482621c214b0f9c68410e7205f (patch) | |
| tree | 7da475234e07731ebcbe2828153d1920d308e436 /src/lib/libssl/ssl_tlsext.c | |
| parent | 3d93c8c633e863047cb14f254d6ed4020afc5c51 (diff) | |
| download | openbsd-03322a1b7dc461482621c214b0f9c68410e7205f.tar.gz openbsd-03322a1b7dc461482621c214b0f9c68410e7205f.tar.bz2 openbsd-03322a1b7dc461482621c214b0f9c68410e7205f.zip | |
Fold SSL_SESSION_INTERNAL back into SSL_SESSION.
ok beck@ tb@
Diffstat (limited to 'src/lib/libssl/ssl_tlsext.c')
| -rw-r--r-- | src/lib/libssl/ssl_tlsext.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/lib/libssl/ssl_tlsext.c b/src/lib/libssl/ssl_tlsext.c index 3ad564964d..d8143ce1be 100644 --- a/src/lib/libssl/ssl_tlsext.c +++ b/src/lib/libssl/ssl_tlsext.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: ssl_tlsext.c,v 1.99 2021/09/10 09:25:29 tb Exp $ */ | 1 | /* $OpenBSD: ssl_tlsext.c,v 1.100 2021/10/25 10:01:46 jsing Exp $ */ |
| 2 | /* | 2 | /* |
| 3 | * Copyright (c) 2016, 2017, 2019 Joel Sing <jsing@openbsd.org> | 3 | * Copyright (c) 2016, 2017, 2019 Joel Sing <jsing@openbsd.org> |
| 4 | * Copyright (c) 2017 Doug Hogan <doug@openbsd.org> | 4 | * Copyright (c) 2017 Doug Hogan <doug@openbsd.org> |
| @@ -243,7 +243,7 @@ tlsext_supportedgroups_server_parse(SSL *s, uint16_t msg_type, CBS *cbs, | |||
| 243 | int i; | 243 | int i; |
| 244 | 244 | ||
| 245 | if (S3I(s)->hs.tls13.hrr) { | 245 | if (S3I(s)->hs.tls13.hrr) { |
| 246 | if (SSI(s)->tlsext_supportedgroups == NULL) { | 246 | if (s->session->tlsext_supportedgroups == NULL) { |
| 247 | *alert = SSL_AD_HANDSHAKE_FAILURE; | 247 | *alert = SSL_AD_HANDSHAKE_FAILURE; |
| 248 | return 0; | 248 | return 0; |
| 249 | } | 249 | } |
| @@ -251,7 +251,7 @@ tlsext_supportedgroups_server_parse(SSL *s, uint16_t msg_type, CBS *cbs, | |||
| 251 | * In the case of TLSv1.3 the client cannot change | 251 | * In the case of TLSv1.3 the client cannot change |
| 252 | * the supported groups. | 252 | * the supported groups. |
| 253 | */ | 253 | */ |
| 254 | if (groups_len != SSI(s)->tlsext_supportedgroups_length) { | 254 | if (groups_len != s->session->tlsext_supportedgroups_length) { |
| 255 | *alert = SSL_AD_ILLEGAL_PARAMETER; | 255 | *alert = SSL_AD_ILLEGAL_PARAMETER; |
| 256 | return 0; | 256 | return 0; |
| 257 | } | 257 | } |
| @@ -260,7 +260,7 @@ tlsext_supportedgroups_server_parse(SSL *s, uint16_t msg_type, CBS *cbs, | |||
| 260 | 260 | ||
| 261 | if (!CBS_get_u16(&grouplist, &group)) | 261 | if (!CBS_get_u16(&grouplist, &group)) |
| 262 | goto err; | 262 | goto err; |
| 263 | if (SSI(s)->tlsext_supportedgroups[i] != group) { | 263 | if (s->session->tlsext_supportedgroups[i] != group) { |
| 264 | *alert = SSL_AD_ILLEGAL_PARAMETER; | 264 | *alert = SSL_AD_ILLEGAL_PARAMETER; |
| 265 | return 0; | 265 | return 0; |
| 266 | } | 266 | } |
| @@ -269,7 +269,7 @@ tlsext_supportedgroups_server_parse(SSL *s, uint16_t msg_type, CBS *cbs, | |||
| 269 | return 1; | 269 | return 1; |
| 270 | } | 270 | } |
| 271 | 271 | ||
| 272 | if (SSI(s)->tlsext_supportedgroups != NULL) | 272 | if (s->session->tlsext_supportedgroups != NULL) |
| 273 | goto err; | 273 | goto err; |
| 274 | 274 | ||
| 275 | if ((groups = reallocarray(NULL, groups_len, | 275 | if ((groups = reallocarray(NULL, groups_len, |
| @@ -290,8 +290,8 @@ tlsext_supportedgroups_server_parse(SSL *s, uint16_t msg_type, CBS *cbs, | |||
| 290 | goto err; | 290 | goto err; |
| 291 | } | 291 | } |
| 292 | 292 | ||
| 293 | SSI(s)->tlsext_supportedgroups = groups; | 293 | s->session->tlsext_supportedgroups = groups; |
| 294 | SSI(s)->tlsext_supportedgroups_length = groups_len; | 294 | s->session->tlsext_supportedgroups_length = groups_len; |
| 295 | } | 295 | } |
| 296 | 296 | ||
| 297 | return 1; | 297 | return 1; |
| @@ -383,8 +383,8 @@ tlsext_ecpf_parse(SSL *s, uint16_t msg_type, CBS *cbs, int *alert) | |||
| 383 | } | 383 | } |
| 384 | 384 | ||
| 385 | if (!s->internal->hit) { | 385 | if (!s->internal->hit) { |
| 386 | if (!CBS_stow(&ecpf, &(SSI(s)->tlsext_ecpointformatlist), | 386 | if (!CBS_stow(&ecpf, &(s->session->tlsext_ecpointformatlist), |
| 387 | &(SSI(s)->tlsext_ecpointformatlist_length))) { | 387 | &(s->session->tlsext_ecpointformatlist_length))) { |
| 388 | *alert = SSL_AD_INTERNAL_ERROR; | 388 | *alert = SSL_AD_INTERNAL_ERROR; |
| 389 | return 0; | 389 | return 0; |
| 390 | } | 390 | } |
