SNMP trap notifications. More...
#include "core/net.h"
#include "snmp/snmp_agent.h"
#include "snmp/snmp_agent_misc.h"
#include "snmp/snmp_agent_trap.h"
#include "mibs/mib2_module.h"
#include "debug.h"
Go to the source code of this file.
Macros | |
#define | TRACE_LEVEL SNMP_TRACE_LEVEL |
Functions | |
error_t | snmpFormatTrapMessage (SnmpAgentContext *context, SnmpVersion version, const char_t *userName, uint_t genericTrapType, uint_t specificTrapCode, const SnmpTrapObject *objectList, uint_t objectListSize) |
Format SNMP Trap message. More... | |
error_t | snmpFormatTrapPdu (SnmpAgentContext *context, SnmpVersion version, const char_t *userName, uint_t genericTrapType, uint_t specificTrapCode, const SnmpTrapObject *objectList, uint_t objectListSize) |
Format Trap-PDU or SNMPv2-Trap-PDU. More... | |
Detailed Description
SNMP trap notifications.
License
SPDX-License-Identifier: GPL-2.0-or-later
Copyright (C) 2010-2024 Oryx Embedded SARL. All rights reserved.
This file is part of CycloneTCP Open.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- Version
- 2.4.4
Definition in file snmp_agent_trap.c.
Macro Definition Documentation
◆ TRACE_LEVEL
#define TRACE_LEVEL SNMP_TRACE_LEVEL |
Definition at line 32 of file snmp_agent_trap.c.
Function Documentation
◆ snmpFormatTrapMessage()
error_t snmpFormatTrapMessage | ( | SnmpAgentContext * | context, |
SnmpVersion | version, | ||
const char_t * | userName, | ||
uint_t | genericTrapType, | ||
uint_t | specificTrapCode, | ||
const SnmpTrapObject * | objectList, | ||
uint_t | objectListSize | ||
) |
Format SNMP Trap message.
- Parameters
-
[in] context Pointer to the SNMP agent context [in] version SNMP version identifier [in] userName User name or community name [in] genericTrapType Generic trap type [in] specificTrapCode Specific code [in] objectList List of object names [in] objectListSize Number of entries in the list
- Returns
- Error code
Definition at line 58 of file snmp_agent_trap.c.
◆ snmpFormatTrapPdu()
error_t snmpFormatTrapPdu | ( | SnmpAgentContext * | context, |
SnmpVersion | version, | ||
const char_t * | userName, | ||
uint_t | genericTrapType, | ||
uint_t | specificTrapCode, | ||
const SnmpTrapObject * | objectList, | ||
uint_t | objectListSize | ||
) |
Format Trap-PDU or SNMPv2-Trap-PDU.
- Parameters
-
[in] context Pointer to the SNMP agent context [in] version SNMP version identifier [in] userName User name or community name [in] genericTrapType Generic trap type [in] specificTrapCode Specific code [in] objectList List of object names [in] objectListSize Number of entries in the list
- Returns
- Error code
Definition at line 186 of file snmp_agent_trap.c.