Provisioning for Integrators
uCentral Data Model Introduction
OpenWiFi 2.x makes it possible for integrators of the SDK to implement commercial products leveraging OpenWiFi Gateway service with vendor supplied provisioning above OpenWiFi SDK. As a minimum, the OpenWiFi 2.0 SDK framework offers a Security service which handles all OpenAPI authentication northbound, and the Gateway service which provides all uCentral websocket interface functionality southbound.
![](https://openwifi.tip.build/~gitbook/image?url=https%3A%2F%2F3797325461-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FoWBagkp2uuXmdJGIwkn0%252Fuploads%252Fgit-blob-368bfa864f18661557a68bedb105ba858d1bc769%252Fimage%2520%2828%29.png%3Falt%3Dmedia&width=768&dpr=4&quality=100&sign=95dabca5&sv=1)
OpenWiFi also provides options to receive telemetry and events over both OpenAPI interface as well as Kafka message bus. When using Kafka, OpenWiFi Gateway directly publishes telemetry and event topics to the bus.
In future sprints of OpenWiFi dynamic device provisioning will be available as an added microservice.
Gateway
OpenWiFi 2.0 Gateway implements the uCentral device management interface. uCentral specifies the data model and interface for management and telemetry of OpenWrt based devices. Gateway uCentral interface is a websocket JSON-RPC based design between OpenWiFi Gateway and the device running uCentral agent.
![](https://openwifi.tip.build/~gitbook/image?url=https%3A%2F%2F3797325461-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FoWBagkp2uuXmdJGIwkn0%252Fuploads%252Fgit-blob-29e791afad8b5b85a221d96f73762955dee61c55%252Fimage%2520%2829%29.png%3Falt%3Dmedia&width=768&dpr=4&quality=100&sign=36e550a7&sv=1)
All communications from Gateway to Device are secured using mutual Transport Layer Security (mTLS). In mTLS systems each endpoint is a unique device sharing the same signed root or intermediate trust. In OpenWiFi each device has a signed certificate, key and device identifier. These are validated by the uCentral-Gateway to establish mTLS session.
Upon successful connection the device exchanges its capabilities with the OpenWiFi SDK. OpenWIFi SDK, via the Gateway microservice will send the entire device provisioning data as a JSON payload. Within OpenWiFi devices, the uCentral agent has a reader and renderer process providing serialization and validation of data sent from cloud. If any data presented can not be processed by the local agent, this is returned within an ERROR message using the same websocket connection.
![](https://openwifi.tip.build/~gitbook/image?url=https%3A%2F%2F3797325461-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FoWBagkp2uuXmdJGIwkn0%252Fuploads%252Fgit-blob-69ddbdff212fb21a5f7ec40a9c04445a68906660%252Fimage%2520%2822%29%2520%282%29.png%3Falt%3Dmedia&width=768&dpr=4&quality=100&sign=bbb86a64&sv=1)
If the device agrees with provisioning information presented, the render process builds calls into the operating system configuration sub-system known as UCI. The Unified Configuration Interface ensures OpenWrt compliant syntax is persisted within the device.
Configuration source of truth is the OpenWiFi SDK. Consistency of device configuration is handled with an applied hash compared by the Gateway for each device. If the value differs on device from that of the stored information in cloud, the device will be immediately resent its configuration from the OpenWiFi SDK Gateway service.
Once present, all configuration data is preserved on device restart.
It is possible to generate device configurations outside of the OpenWiFi 2.0 SDK as shown in the minimum SDK image at the start of this page. This may occur for some integrations or may occur when the OpenWiFi Provisioning microservice is not present. In this way, integrators of commercial products are welcome to build device provisioning outside of OpenWiFi and use the OpenWiFi cloud to manage the scale, state, security and validation of device websocket communications.
Last updated