-/* $OpenBSD: ssl_locl.h,v 1.335 2021/04/19 17:03:39 jsing Exp $ */
+/* $OpenBSD: ssl_locl.h,v 1.336 2021/04/19 17:26:39 jsing Exp $ */
/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
* All rights reserved.
*
size_t *overhead);
int tls12_record_layer_read_protected(struct tls12_record_layer *rl);
int tls12_record_layer_write_protected(struct tls12_record_layer *rl);
+const EVP_AEAD *tls12_record_layer_aead(struct tls12_record_layer *rl);
+const EVP_CIPHER *tls12_record_layer_cipher(struct tls12_record_layer *rl);
void tls12_record_layer_set_aead(struct tls12_record_layer *rl,
const EVP_AEAD *aead);
void tls12_record_layer_set_cipher_hash(struct tls12_record_layer *rl,
char ctype[SSL3_CT_NUMBER];
STACK_OF(X509_NAME) *ca_names;
- const EVP_CIPHER *new_sym_enc;
- const EVP_AEAD *new_aead;
-
int cert_request;
} tmp;
-/* $OpenBSD: t1_enc.c,v 1.137 2021/04/19 17:03:39 jsing Exp $ */
+/* $OpenBSD: t1_enc.c,v 1.138 2021/04/19 17:26:39 jsing Exp $ */
/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
* All rights reserved.
*
const EVP_AEAD *aead;
char is_read, use_client_keys;
- cipher = S3I(s)->tmp.new_sym_enc;
- aead = S3I(s)->tmp.new_aead;
+ aead = tls12_record_layer_aead(s->internal->rl);
+ cipher = tls12_record_layer_cipher(s->internal->rl);
/*
* is_read is true if we have just read a ChangeCipherSpec message,
if (!ssl_get_handshake_evp_md(s, &handshake_hash))
return (0);
- S3I(s)->tmp.new_aead = aead;
- S3I(s)->tmp.new_sym_enc = cipher;
S3I(s)->hs.tls12.mac_secret_size = mac_secret_size;
tls12_record_layer_set_aead(s->internal->rl, aead);
-/* $OpenBSD: tls12_record_layer.c,v 1.25 2021/03/29 16:19:15 jsing Exp $ */
+/* $OpenBSD: tls12_record_layer.c,v 1.26 2021/04/19 17:26:39 jsing Exp $ */
/*
* Copyright (c) 2020 Joel Sing <jsing@openbsd.org>
*
return tls12_record_protection_engaged(rl->write);
}
+const EVP_AEAD *
+tls12_record_layer_aead(struct tls12_record_layer *rl)
+{
+ return rl->aead;
+}
+
+const EVP_CIPHER *
+tls12_record_layer_cipher(struct tls12_record_layer *rl)
+{
+ return rl->cipher;
+}
+
void
tls12_record_layer_set_aead(struct tls12_record_layer *rl, const EVP_AEAD *aead)
{