tls13_server.c File Reference

Handshake message processing (TLS 1.3 server) More...

#include "tls.h"
#include "tls_handshake.h"
#include "tls_server_extensions.h"
#include "tls_server_misc.h"
#include "tls_extensions.h"
#include "tls_transcript_hash.h"
#include "tls_ffdhe.h"
#include "tls_misc.h"
#include "tls13_server.h"
#include "tls13_server_extensions.h"
#include "tls13_server_misc.h"
#include "tls13_ticket.h"
#include "tls13_misc.h"
#include "debug.h"

Go to the source code of this file.

Macros

#define TRACE_LEVEL   TLS_TRACE_LEVEL
 

Functions

error_t tls13SendHelloRetryRequest (TlsContext *context)
 Send HelloRetryRequest message. More...
 
error_t tls13SendEncryptedExtensions (TlsContext *context)
 Send EncryptedExtensions message. More...
 
error_t tls13SendNewSessionTicket (TlsContext *context)
 Send NewSessionTicket message. More...
 
error_t tls13FormatHelloRetryRequest (TlsContext *context, Tls13HelloRetryRequest *message, size_t *length)
 Format HelloRetryRequest message. More...
 
error_t tls13FormatEncryptedExtensions (TlsContext *context, Tls13EncryptedExtensions *message, size_t *length)
 Format EncryptedExtensions message. More...
 
error_t tls13FormatNewSessionTicket (TlsContext *context, Tls13NewSessionTicket *message, size_t *length)
 Format NewSessionTicket message. More...
 

Detailed Description

Handshake message processing (TLS 1.3 server)

License

SPDX-License-Identifier: GPL-2.0-or-later

Copyright (C) 2010-2024 Oryx Embedded SARL. All rights reserved.

This file is part of CycloneSSL Open.

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.

Author
Oryx Embedded SARL (www.oryx-embedded.com)
Version
2.4.0

Definition in file tls13_server.c.

Macro Definition Documentation

◆ TRACE_LEVEL

#define TRACE_LEVEL   TLS_TRACE_LEVEL

Definition at line 32 of file tls13_server.c.

Function Documentation

◆ tls13FormatEncryptedExtensions()

error_t tls13FormatEncryptedExtensions ( TlsContext context,
Tls13EncryptedExtensions message,
size_t *  length 
)

Format EncryptedExtensions message.

Parameters
[in]contextPointer to the TLS context
[out]messageBuffer where to format the EncryptedExtensions message
[out]lengthLength of the resulting EncryptedExtensions message
Returns
Error code

Definition at line 359 of file tls13_server.c.

◆ tls13FormatHelloRetryRequest()

error_t tls13FormatHelloRetryRequest ( TlsContext context,
Tls13HelloRetryRequest message,
size_t *  length 
)

Format HelloRetryRequest message.

Parameters
[in]contextPointer to the TLS context
[out]messageBuffer where to format the HelloRetryRequest message
[out]lengthLength of the resulting HelloRetryRequest message
Returns
Error code

Definition at line 248 of file tls13_server.c.

◆ tls13FormatNewSessionTicket()

error_t tls13FormatNewSessionTicket ( TlsContext context,
Tls13NewSessionTicket message,
size_t *  length 
)

Format NewSessionTicket message.

Parameters
[in]contextPointer to the TLS context
[out]messageBuffer where to format the NewSessionTicket message
[out]lengthLength of the resulting NewSessionTicket message
Returns
Error code

Definition at line 489 of file tls13_server.c.

◆ tls13SendEncryptedExtensions()

error_t tls13SendEncryptedExtensions ( TlsContext context)

Send EncryptedExtensions message.

The server sends the EncryptedExtensions message immediately after the ServerHello message. The EncryptedExtensions message contains extensions that can be protected

Parameters
[in]contextPointer to the TLS context
Returns
Error code

Definition at line 138 of file tls13_server.c.

◆ tls13SendHelloRetryRequest()

error_t tls13SendHelloRetryRequest ( TlsContext context)

Send HelloRetryRequest message.

The server will send this message in response to a ClientHello message if it is able to find an acceptable set of parameters but the ClientHello does not contain sufficient information to proceed with the handshake

Parameters
[in]contextPointer to the TLS context
Returns
Error code

Definition at line 66 of file tls13_server.c.

◆ tls13SendNewSessionTicket()

error_t tls13SendNewSessionTicket ( TlsContext context)

Send NewSessionTicket message.

At any time after the server has received the client Finished message, it may send a NewSessionTicket message

Parameters
[in]contextPointer to the TLS context
Returns
Error code

Definition at line 196 of file tls13_server.c.