1.2.6 Authentication, BSS & HTTP provisioning
This topic provides information how contexts are used. To simplify other interfaces and encapsulate information the WINC Driver uses context structures in various places to pass around information. Interface functions are provided to create, query and update these contexts as appropriate for their function.
Authentication Contexts
The authentication context contains information relevant to the authentication mechanisms used in Wi-Fi. Currently supported are Open, WEP and WPA-PSK.
The structure WDRV_WINC_AUTH_CONTEXT is provided to contain the context. To initialize a context the function WDRV_WINC_AuthCtxSetDefaults is provided, this ensures the context is in a known state. The function WDRV_WINC_AuthCtxIsValid is provided to test if a context is valid. Each authentication type has at least one function which can be used to configure the type of authentication algorithm used as well as the parameters which are required.
BSS Contexts
The BSS context contains information relevant to a BSS such as SSID and channel.
The structure WDRV_WINC_BSS_CONTEXT is provided to contain the context. To initialize a context the function WDRV_WINC_BSSCtxSetDefaults is provided, this ensures the context is in a known state. The function WDRV_WINC_BSSCtxIsValid is provided to test if a context is valid. In some applications a BSS context is valid even if an SSID is blank therefore this function can be informed whether a blank SSID is valid or not.
The SSID of the BSS can be configured using the function WDRV_WINC_BSSCtxSetSSID.
The channel of the BSS can be configure using the function WDRV_WINC_BSSCtxSetChannel.
In some applications a BSS can be cloaked therefore the state can be configured in a BSS context using the function WDRV_WINC_BSSCtxSetSSIDVisibility to indicate if an BSS is considered visible or not.
HTTP Provisioning Contexts
The HTTP Provisioning Context contains information relevant to a provisioning Soft-AP.
The structure WDRV_WINC_HTTP_PROV_CONTEXT is provided to contain the context. To initialize a context the function WDRV_WINC_HTTPProvCtxSetDefaults is provided, this ensures the context is in a known state. The domain name of the provisioning HTTP server is configured using the function WDRV_WINC_HTTPProvCtxSetDomainName.
A provisioning HTTP server can perform wildcard DNS mapping to force a HTTP client to connect irrespective of the URL used, to configure this option the function WDRV_WINC_HTTPProvCtxSetURLWildcard is provided.
A callback for the provisioning service can be configure using the function WDRV_WINC_HTTPProvCtxSetConnectCallback.