Extracted from Pike v7.8 release 866 at 2016-11-06.
pike.ida.liu.se
[Top]
Protocols
Protocols.SNMP
Protocols.SNMP.protocol

Method Protocols.SNMP.protocol()->trap()


Method trap

int trap(mapping varlist, string oid, int type, int spectype, int ticks, string|void locip, string|void remaddr, int|void remport)

Description

send an SNMP-v1 trap

Parameter varlist

a mapping of OIDs to include in trap

oid1 : array
Array
string type

data type such as tick, oid, gauge, etc

mixed data

data to return for oid1


oid2 : array
Array
string type

data type such as tick, oid, gauge, etc

mixed data

data to return for oid2


oidn : array
Array
string type

data type such as tick, oid, gauge, etc

mixed data

data to return for oidn



Parameter oid
Parameter type

generic trap-type

Parameter spectype

specific trap-type

Parameter ticks

uptime

Parameter locip

originating ip address of the trap

Parameter remaddr
Parameter remport

address and UDP to send trap to

Returns

request id