openHiTLS API openHiTLS 0.1.0-Alpha1

◆ HITLS_SetVersion()

int32_t HITLS_SetVersion ( HITLS_Ctx ctx,
uint32_t  minVersion,
uint32_t  maxVersion 
)

Set the supported version number range.

参数
ctx[OUT] TLS connection handle
minVersion[IN] Minimum version number supported.
maxVersion[IN] Maximum version number supported.
注意
The maximum version number and minimum version number must be both TLS and DTLS. Currently, only DTLS 1.2 is supported. This function is used together with the full configuration interfaces, such as HITLS_CFG_NewDTLSConfig and HITLS_CFG_NewTLSConfig. If the TLS full configuration is configured, only the TLS version can be set. If full DTLS configuration is configured, only the DTLS version can be set.
返回值
HITLS_SUCCESS,ifsuccessful.
HITLS_NULL_INPUT,configis null.