API参考
载入中...
搜索中...
未找到
recv_process.h
1/*
2 * This file is part of the openHiTLS project.
3 *
4 * openHiTLS is licensed under the Mulan PSL v2.
5 * You can use this software according to the terms and conditions of the Mulan PSL v2.
6 * You may obtain a copy of Mulan PSL v2 at:
7 *
8 * http://license.coscl.org.cn/MulanPSL2
9 *
10 * THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
11 * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
12 * MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
13 * See the Mulan PSL v2 for more details.
14 */
15
16#ifndef RECV_PROCESS_H
17#define RECV_PROCESS_H
18
19#include <stdint.h>
20#include "tls.h"
21#include "hs_msg.h"
22
23#ifdef __cplusplus
24extern "C" {
25#endif
26
27int32_t Tls12ServerRecvClientHelloProcess(TLS_Ctx *ctx, const HS_Msg *msg, bool isNeedClientHelloCb);
28
29/*
30 * @brief Server processes DTLS client hello message
31 *
32 * @param ctx [IN] TLS context
33 * @param msg [IN] client hello message
34 *
35 * @retval HITLS_SUCCESS
36 * @retval For other error codes, see hitls_error.h
37 */
38#ifdef HITLS_TLS_PROTO_DTLS12
39int32_t DtlsServerRecvClientHelloProcess(TLS_Ctx *ctx, const HS_Msg *msg);
40#endif
41
42/*
43 * @brief Dtls client processes hello verify request message
44 *
45 * @param ctx [IN] TLS context
46 * @param msg [IN] hello verify request message
47 *
48 * @retval HITLS_SUCCESS
49 * @retval For other error codes, see hitls_error.h
50 */
51#ifdef HITLS_TLS_PROTO_DTLS12
52int32_t DtlsClientRecvHelloVerifyRequestProcess(TLS_Ctx *ctx, HS_Msg *msg);
53#endif
54
64int32_t ClientRecvServerHelloProcess(TLS_Ctx *ctx, const HS_Msg *msg);
65
75int32_t RecvCertificateProcess(TLS_Ctx *ctx, const HS_Msg *msg);
76
86int32_t ClientRecvServerKxProcess(TLS_Ctx *ctx, HS_Msg *msg);
87
96int32_t ClientRecvCertRequestProcess(TLS_Ctx *ctx);
97
105int32_t ClientRecvServerHelloDoneProcess(TLS_Ctx *ctx);
106
116int32_t ServerRecvClientKxProcess(TLS_Ctx *ctx, const HS_Msg *msg);
117
126int32_t ServerRecvClientCertVerifyProcess(TLS_Ctx *ctx);
127
136int32_t Tls12ClientRecvNewSeesionTicketProcess(TLS_Ctx *ctx, HS_Msg *hsMsg);
137
146int32_t Tls13ClientRecvNewSessionTicketProcess(TLS_Ctx *ctx, HS_Msg *hsMsg);
147
148int32_t Tls12ServerRecvFinishedProcess(TLS_Ctx *ctx, const HS_Msg *msg);
149
150int32_t Tls12ClientRecvFinishedProcess(TLS_Ctx *ctx, const HS_Msg *msg);
151
161#ifdef HITLS_TLS_PROTO_DTLS12
162int32_t DtlsServerRecvFinishedProcess(TLS_Ctx *ctx, const HS_Msg *msg);
163#endif
164
174#ifdef HITLS_TLS_PROTO_DTLS12
175int32_t DtlsClientRecvFinishedProcess(TLS_Ctx *ctx, const HS_Msg *msg);
176#endif
177
187int32_t Tls13ServerRecvClientHelloProcess(TLS_Ctx *ctx, HS_Msg *msg);
188
198int32_t Tls13ClientRecvServerHelloProcess(TLS_Ctx *ctx, const HS_Msg *msg);
199
209int32_t Tls13ClientRecvEncryptedExtensionsProcess(TLS_Ctx *ctx, const HS_Msg *msg);
210
220int32_t Tls13ClientRecvCertRequestProcess(TLS_Ctx *ctx, const HS_Msg *msg);
221
231int32_t Tls13RecvCertificateProcess(TLS_Ctx *ctx, const HS_Msg *msg);
232
242int32_t Tls13RecvCertVerifyProcess(TLS_Ctx *ctx);
243
253int32_t Tls13ClientRecvFinishedProcess(TLS_Ctx *ctx, const HS_Msg *msg);
254
264int32_t Tls13ServerRecvFinishedProcess(TLS_Ctx *ctx, const HS_Msg *msg);
265
266int32_t ProcessCertCallback(TLS_Ctx *ctx);
267#ifdef __cplusplus
268}
269#endif /* end __cplusplus */
270
271#endif /* end RECV_PROCESS_H */
定义 hs_msg.h:369