Warda-DNSDocs Warda: from ward — to protect, guardian
v0.9.3

Kinds of devices

From 0.7.10 (store.Kinds, internal/classify/kind.go). The column Kind of Household → Devices says what a device is. Up to 0.7.9 it held two values, Device and Server; there are now fifteen, each with its icon in the list:

kind In the list
normal Device (any other device: the default)
phone Phone
tablet Tablet
computer Computer
server Server
firewall Firewall / router
network Access point / switch
printer Printer
tv TV / media box
console Game console
speaker Smart speaker
camera Camera
iot Connected object (IoT)
nas NAS / storage
watch Watch

Automatic. While nobody chooses, the list shows Automatic: … with the kind Warda proposes (suggested_kind) from what it sees of the device, in this order: the words of its name, of its model or of the title of its page (a watch before anything of Apple, a console before a network switch); a router or a firewall recognised; a switch, then a server, by their names; its maker (Sonos, Nintendo, Sony Interactive, Valve, Raspberry Pi); the default group it looks like (printers, cameras, Wi-Fi and network, TVs and consoles, NAS and home lab, connected objects); its system (an iPhone or an Android: a phone; a Mac, Windows or a Linux desktop: a computer); a device that shows nothing but a private hardware address is proposed as a phone (phones are the ones that hide theirs). Nothing tells: Device. A proposal is only shown: it is never written in the place of a choice, and a kind an administrator chose is never replaced (kind_set), by Warda, by a merge of two devices, by a backup restored nor by the configuration given to the secondary of a pair. Choosing Automatic again gives the choice back to Warda. The list is filtered by kind (the kind shown, with the count of each).

What a kind changes. Choosing "Server" did two things up to 0.7.9, and both are kept:

  • the regular automatic calls of the machine never make suggestions (Learning: held with the reason server). From 0.7.10 the same holds for the four kinds of machines that work alone, without anyone in front of them: server, NAS / storage, firewall / router and access point / switch (store.Unattended), because their calls at fixed intervals, day and night, are what the learning takes for tracking on a device someone uses;
  • on the map of the network, the machine is taken as plugged by a cable rather than on Wi-Fi when nothing tells otherwise: from 0.7.10 the server and the NAS / storage both are.

Both follow the kind chosen by an administrator, never a proposal. Up to 0.7.13 the other kinds changed the icon and the filter of the list only. From 0.8.0 two functions also read the kind (the one chosen, else the one Warda proposes), and only to propose or to rate, never to block by themselves: the restricted mode for connected objects is offered for the TVs and media boxes, smart speakers, cameras, connected objects and printers, with a warning when a device in that mode now looks like a phone, a tablet, a computer or a watch; and the exposure on the Internet rates higher a port that leads to a camera, a connected object or a TV, and lower a web server on a device of the kind server. No rule, no report, no time limit reads them.

API. PATCH /api/v1/devices/{id} {"kind": "nas"} takes each of the fifteen kinds, or "" to give the choice back (any other value: 400, the kinds listed); same rights as before. A device carries kind, kind_set and, while it is not chosen, suggested_kind. warda device -kind KIND ID sets it from the box. The administration log records kind=<kind> (kind=automatic when the choice is given back).

Migration. The table devices is rebuilt at the first start of 0.7.10 (the check of its column kind lists the kinds): the devices keep their id, their name, their person, their group and their history; a device that was a server stays a server, chosen (kind_set); the others are proposed a kind. See what the previous version can no longer do.