openHiTLS API openHiTLS 0.1.0-Alpha1
宏定义 | 类型定义 | 函数
hitls_alpn.h 文件参考
hitls_alpn.h 的引用(Include)关系图:

浏览源代码.

宏定义

#define HITLS_ALPN_ERR_OK   0 /* Correct execution. */
 
#define HITLS_ALPN_ERR_ALERT_WARNING   1 /* Execution error, sent warning alert. */
 
#define HITLS_ALPN_ERR_ALERT_FATAL   2 /* Execution error, sent fatal alert. */
 
#define HITLS_ALPN_ERR_NOACK   3 /* Execution exception, ignore processing. */
 

类型定义

typedef int32_t(* HITLS_AlpnSelectCb) (HITLS_Ctx *ctx, uint8_t **selectedProto, uint8_t *selectedProtoSize, uint8_t *clientAlpnList, uint32_t clientAlpnListSize, void *userData)
 Callback prototype for selecting the ALPN protocol on the server, which is used to select the application layer protocol during ALPN negotiation.
 

函数

int32_t HITLS_CFG_SetAlpnProtos (HITLS_Config *config, const uint8_t *alpnProtos, uint32_t alpnProtosLen)
 Sets the ALPN list on the client, which is used to negotiate the application layer protocol with the server in the handshake phase.
 
int32_t HITLS_CFG_SetAlpnProtosSelectCb (HITLS_Config *config, HITLS_AlpnSelectCb callback, void *userData)
 Sets the ALPN selection callback on the server.
 
int32_t HITLS_SetAlpnProtos (HITLS_Ctx *ctx, const uint8_t *protos, uint32_t protosLen)
 Sets the client ALPN list, which is used to negotiate the application layer protocol with the server in the handshake phase.
 
int32_t HITLS_GetSelectedAlpnProto (HITLS_Ctx *ctx, uint8_t **proto, uint32_t *protoLen)
 Obtaining the ALPN Negotiation Result