SharkSSL C/C++ Reference
TLS, cryptography, certificates, and PSA integration
WscState Struct Reference

#include <WsClientLib.h>

Data Fields

U8 * recBuf
 The receive buffer must be set when not in secure mode. More...
 
U8 * sendBuf
 The send buffer must be set when not in secure mode. More...
 
int recBufLen
 The receive buffer length must be set to the recBuf length. More...
 
int sendBufLen
 The send buffer length must be set to the sendBuf length. More...
 
SharkSslCon * scon
 The SharkSslCon object must be set when using secure mode. More...
 
SOCKET * sock
 The SOCKET object must be set. More...
 
int frameLen
 The WebSocket frame length. More...
 
int bytesRead
 Read frame data until: frameLen - bytesRead = 0. More...
 
U8 * overflowPtr
 
int overflowLen
 
int frameHeaderIx
 
U8 frameHeader [4]
 
U8 isTimeout
 Set when the read function returns due to a timeout. More...
 

Detailed Description

WebSocket Client State Information, initialize using: WscState wss={0}; however, several members must be set.

Field Documentation

◆ bytesRead

int WscState::bytesRead

Read frame data until: frameLen - bytesRead = 0.

◆ frameHeader

U8 WscState::frameHeader[4]

◆ frameHeaderIx

int WscState::frameHeaderIx

◆ frameLen

int WscState::frameLen

The WebSocket frame length.

◆ isTimeout

U8 WscState::isTimeout

Set when the read function returns due to a timeout.

◆ overflowLen

int WscState::overflowLen

◆ overflowPtr

U8* WscState::overflowPtr

◆ recBuf

U8* WscState::recBuf

The receive buffer must be set when not in secure mode.

◆ recBufLen

int WscState::recBufLen

The receive buffer length must be set to the recBuf length.

◆ scon

SharkSslCon* WscState::scon

The SharkSslCon object must be set when using secure mode.

◆ sendBuf

U8* WscState::sendBuf

The send buffer must be set when not in secure mode.

◆ sendBufLen

int WscState::sendBufLen

The send buffer length must be set to the sendBuf length.

◆ sock

SOCKET* WscState::sock

The SOCKET object must be set.