API参考
载入中...
搜索中...
未找到
app_server.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 HITLS_APP_SERVER_H
17
#define HITLS_APP_SERVER_H
18
19
#include <stdint.h>
20
#include "app_provider.h"
21
#include "app_sm.h"
22
#include "bsl_types.h"
23
24
#ifdef __cplusplus
25
extern
"C"
{
26
#endif
27
28
/* Server parameters structure */
29
typedef
struct
{
30
/* Listen parameters */
31
char
*bindAddr;
32
int
port;
33
int
backlog;
34
35
/* Protocol parameters */
36
char
*protocol;
37
char
*cipherSuites;
38
39
/* Certificate parameters */
40
char
*caFile;
41
char
*caChain;
42
bool
verifyClient;
43
int
verifyDepth;
44
45
/* TLCP parameters */
46
char
*tlcpEncCert;
47
char
*tlcpEncKey;
48
char
*tlcpSignCert;
49
char
*tlcpSignKey;
50
51
/* Service parameters */
52
bool
acceptOnce;
53
int
maxConnections;
54
55
/* Output parameters */
56
bool
quiet;
57
bool
state;
58
59
/* Format parameters */
60
BSL_ParseFormat certFormat;
61
BSL_ParseFormat keyFormat;
62
AppProvider
*provider;
63
#ifdef HITLS_APP_SM_MODE
64
HITLS_APP_SM_Param *smParam;
65
#endif
66
}
HITLS_ServerParams
;
67
74
int
HITLS_ServerMain(
int
argc,
char
*argv[]);
75
76
#ifdef __cplusplus
77
}
78
#endif
79
80
#endif
/* HITLS_APP_SERVER_H */
AppProvider
定义
app_provider.h:25
HITLS_ServerParams
定义
app_server.h:29
apps
include
app_server.h
制作者
1.15.0