summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authorjsing <>2020-01-02 06:23:16 +0000
committerjsing <>2020-01-02 06:23:16 +0000
commit8193c632be0f53faee43b4194dff63a4e6f9ea41 (patch)
tree26462550e7dbd52d9dcb5b6088548dec141cb29d /src/lib
parentb2116ee7f867c3373e14c82f727d8d0021f69af5 (diff)
downloadopenbsd-8193c632be0f53faee43b4194dff63a4e6f9ea41.tar.gz
openbsd-8193c632be0f53faee43b4194dff63a4e6f9ea41.tar.bz2
openbsd-8193c632be0f53faee43b4194dff63a4e6f9ea41.zip
Provide TLSEXT_TYPE_* aliases for TLS 1.3.
OpenSSL decided to use their own names for two of the TLS 1.3 extensions, rather than using the names given in the RFC. Provide aliases for these so that code written to work with OpenSSL also works with LibreSSL (otherwise everyone gets to provide their own workarounds). Issue noted by d3x0r on github. ok inoguchi@ tb@
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/libssl/tls1.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/lib/libssl/tls1.h b/src/lib/libssl/tls1.h
index cb68bbb562..2230f0bab8 100644
--- a/src/lib/libssl/tls1.h
+++ b/src/lib/libssl/tls1.h
@@ -1,4 +1,4 @@
1/* $OpenBSD: tls1.h,v 1.39 2019/03/19 16:53:03 jsing Exp $ */ 1/* $OpenBSD: tls1.h,v 1.40 2020/01/02 06:23:16 jsing 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 *
@@ -280,6 +280,15 @@ extern "C" {
280#define TLSEXT_TYPE_key_share 51 280#define TLSEXT_TYPE_key_share 51
281#endif 281#endif
282 282
283/*
284 * TLS 1.3 extension names from OpenSSL, where they decided to use a different
285 * name from that given in RFC 8446.
286 */
287#if defined(LIBRESSL_HAS_TLS1_3)
288#define TLSEXT_TYPE_psk TLSEXT_TYPE_pre_shared_key
289#define TLSEXT_TYPE_psk_kex_modes TLSEXT_TYPE_psk_key_exchange_modes
290#endif
291
283/* Temporary extension type */ 292/* Temporary extension type */
284#define TLSEXT_TYPE_renegotiate 0xff01 293#define TLSEXT_TYPE_renegotiate 0xff01
285 294