THINGSD(8)

NAME
thingsd - things OpenBSD proxy daemon

SYNOPSIS
thingsd [-dv]

DESCRIPTION
The thingsd OpenBSD proxy daemon provides a mechanism for clients and client processes to communicate with an array of serial and IoT things. At its core, thingsd is primarily a data aggregator and repeater, in that it waits for packets to swap between subscriber clients and things. However, thingsd also provides TLS and password control over those connections, including client limits.

On the client side, thingsd sets up TCP/IP sockets to transmit packets to and from things. On the server side, thingsd can connect to any serial device which has a viable file descriptor, create a persistent connection to the IP address of a device transmitting packets, or setup a UDP listener on the network to receive broadcasted packets. Devices tested include: ESP8266/ESP32 modules, on both the serial and network sides, XBee Series 2 coordinators connected in a mesh network, and NF24 devices. To transmit to an IP address, which does not allow persistence, thingsd will create an ad hoc connection, transmit a packet, and detach. The thingsd proxy daemon is agnostic about packet data.

The options are as follows:

-d  Do not daemonize. If this option is specified, thingsd will run in the foreground and log to stderr.

-v  This option allows thingsd to send DEBUG priority messages to syslog.

Subscribers to a thing pass a simple, human-readable packet to thingsd. The format is as follows, without the line breaks and tabs. This example is only for initial readability and help in understanding the format!

Subscription packets must begin with 3 * 0x7E

    ~~~subscribe{
    	{name,"CLIENTNAME"},
    	{things{
    		thing{"dev1","pass"},
    		thing{"dev2","pass"}
    		}
    	}
    }

An accurate packet would not include linebreaks.

thingsd is usually started at boot time, and can be enabled by adding thingsd to the pkg_scripts line in /etc/rc.conf.local. See rc(8) and rc.conf(8) for more information on the boot process and enabling daemons.

When thingsd starts up, it reads settings from its configuration file, typically thingsd.conf(5), and creates sockets and file descriptor connections.

FILES
/etc/thingsd.conf
    Default configuration file.
/var/run/thingsd.sock
    Socket file for communication with thingsctl(8).

SEE ALSO
thingsd.conf(5), rc(8), rc.conf(8), thingsctl(8)

HISTORY
The busybeed program first began development on OpenBSD 5.9. The thingsd program refactoring and rename began on OpenBSD 6.4. thingsd name by Matthew Graybosch.

AUTHORS
-nosplit The thingsd program was written by Tracey Emery <tracey@traceyemery.net>.