mirror of
https://github.com/rzuasti/oott.git
synced 2026-07-08 19:21:54 +02:00
So that consumers of the events API can tell whether a sighting came from the ARP scanner or the mDNS listener. Adds a DeviceEventScanner enum (Arp / Mdns) plumbed from each scanner's call site through to a new scanner column on device_events, exposed via the existing events endpoint and OpenAPI schema. Pre-existing rows are backfilled with 'ARP' since that was the only scanner before mDNS. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
7 lines
639 B
SQL
7 lines
639 B
SQL
INSERT INTO device_events (id, mac_address, created_on, event_type, ipv4_address, vendor, scanner)
|
|
VALUES (1, 'aa:aa:aa:aa:aa:aa', '2026-01-01T11:11:11+00:00', 'NewDevice', '192.168.0.1', 'Vendor 1', 'ARP');
|
|
INSERT INTO device_events (id, mac_address, created_on, event_type, ipv4_address, vendor, scanner)
|
|
VALUES (2, 'bb:bb:bb:bb:bb:bb', '2026-02-03T13:14:15+00:00', 'DeviceSeen', '192.168.0.2', 'Vendor 2', 'mDNS');
|
|
INSERT INTO device_events (id, mac_address, created_on, event_type, ipv4_address, vendor, scanner)
|
|
VALUES (3, 'aa:aa:aa:aa:aa:aa', '2026-03-10T09:00:00+00:00', 'DeviceSeen', '192.168.0.1', 'Vendor 1', 'ARP');
|