DeterministicESPAsyncWebServer v6.27.1
Zero-allocation, bounded-execution async HTTP server for ESP32
Loading...
Searching...
No Matches
snmp_notify.h File Reference

Outbound SNMP notifications - Trap and InformRequest (DETWS_ENABLE_SNMP_TRAP). More...

#include "ServerConfig.h"
#include <stddef.h>
#include <stdint.h>

Go to the source code of this file.

Detailed Description

Outbound SNMP notifications - Trap and InformRequest (DETWS_ENABLE_SNMP_TRAP).

Lets the agent push events to a manager instead of only answering polls: SNMPv2c (RFC 3416) and, when DETWS_ENABLE_SNMP_V3 is set, SNMPv3 USM (authPriv) notifications. Every notification carries the mandatory sysUpTime.0 and snmpTrapOID.0 bindings plus any caller varbinds. Split, like the other services, into a host-testable PDU builder and an ESP32 UDP send:

  • snmp_notify_build_v2c() is a pure BER function, unit-tested on the host (env:native_snmp_trap).
  • snmp_trap_v2c() / snmp_inform_v2c() (and the v3 variants) build and send to a manager over the transport-layer UDP service (port 162 by convention).

Definition in file snmp_notify.h.