Collecting SNMP Traps with Cribl Stream
Network device traps into the pipeline, one source at a time.
SNMP traps in a pipeline
Cribl Stream supports receiving data from SNMP traps. Per the SNMP Trap Source documentation, this Source is of Push type, has no TLS support, and no Event Breaker support either. Any device that can emit SNMP traps pushes them into Stream over UDP, and Stream decodes each packet, so you can act on the SNMP metadata: drop it, route it, forward the packet verbatim to another SNMP destination, or deliver the data to non-SNMP destinations such as Splunk, Syslog, and S3.
Setting up the trap source
On the top bar, select Products and then Cribl Stream, and under Worker Groups select a Worker Group. Two paths add the Source: Routing > QuickConnect (Stream) or Collect (Edge), where you select Add Source and choose Select Existing or Add New; or Data > Sources (Stream), More > Sources (Edge), select the Source, then Add Source.
In the New Source modal, the General Settings are:
- Input ID: a unique name for this Source. The default Source is prefilled with
in_snmp_trap, which can't be changed via the UI; a clone gets-CLONEappended to the original. - Description: optionally, enter a description.
- Address: the address to bind on. Defaults to
0.0.0.0(all addresses). - UDP Port: the port that receives traps. Defaults to
162. - Tags: optional tags to filter and group Sources in the UI; they are not added to processed events.
One detail changes which port you use: except in Cribl.Cloud, Cribl Stream ships with an SNMP Trap Source preconfigured to listen on port 9162. Clone it or modify it directly, then enable it. Finish with Save and Commit & Deploy.
Authentication. SNMPv3 authentication provides secure access through optional user authentication and decryption of incoming data packets, at three levels: user name checking without authentication, user authentication without privacy, or user authentication with privacy. Toggle SNMPv3 authentication on to reveal the parameters and add at least one user via v3 Name; Add user adds more credentials. The authentication protocol, authentication key, privacy protocol, and privacy key can all be unique per user. For authentication to succeed, the user name, protocol, and key must match between the Source and the device, and decryption additionally requires the privacy protocol and key to match.
- Authentication protocol:
Nonechecks the user name only. Otherwise, chooseMD5,SHA1,SHA224,SHA256,SHA384, orSHA512. - Privacy protocol:
Noneauthenticates without decrypting. Otherwise, chooseAES128,AES256b (Blumenthal), orAES2556r (Reeder). - Allow unmatched traps: on, and traps matching no configured user pass through unauthenticated and undecrypted. Off (the default), and Cribl Stream drops traps without a correctly configured user name.
Cribl Stream logs authentication failures at the debug level, and decryption failures at the debug level as well.
Persistent queue. The Persistent Queue Settings tab buffers and preserves incoming events when a downstream Destination has an outage or backpressure. On Cribl-managed Cloud Workers (Enterprise plan), only the Enable persistent queue toggle is exposed; enabled, PQ runs in Always On mode with a maximum of 1 GB of disk per PQ-enabled Source, per Worker Process. On on-prem and hybrid deployments, the full controls apply:
- Mode:
Always On(default) always writes events to the persistent queue before processing.Smartengages PQ only when the Source detects backpressure. Smart mode is deprecated for Source persistent queues on hybrid and on-prem deployments; affected configurations migrate toAlways Onautomatically in January 2027. - Buffer size limit (bytes): maximum memory buffered before disk flush. Range
64KBto10MB, default1MB. Replaces the deprecated events-based limit as of version 4.18.0. - Commit frequency: events sent downstream before committing that Stream has read them. Defaults to
42. - File size limit: volume stored per queue file before it closes. Defaults to
10 MB; must be at least the Buffer size limit, or the combination is rejected. - Queue size limit: maximum disk per Worker Process. Defaults to
5GB, up to1 TBunless Group or Fleet settings set a different PQ size limit. - Queue file path: defaults to
$CRIBL_HOME/state/queues, with the worker ID and input ID appended beneath it. - Compression: optional codec after a file closes. Defaults to
None;Gzipis available. - Queue-full behavior:
Block(default) accepts no new data until the queue has capacity and returns block signals to backpressure-capable senders;Drop new datadiscards incoming events, leaving the queue unchanged.
In Cribl Stream 4.1 and newer, the Source persistent queue default Mode is Always On.
Processing. In Fields, you can define new fields or modify existing ones with JavaScript expressions, similar to the Eval function: a Field Name (new or existing) and a Value expression that computes it, including a constant. In Pre-Processing, a single existing Pipeline or Pack can process this input's data before it goes through the Routes.
Advanced. Include varbind types puts varbind types into the varbinds field on each event and is required for the SNMP Trap Serialize Function when serializing to an SNMP Trap Destination (off by default). IP allowlist regex matches the IPs allowed to send data (defaults to .*, all IPs). Buffer size limit (events) caps events buffered while downstream blocks (defaults to 1000). UDP socket buffer size (bytes) sets the SO_RCVBUF socket option (minimum 256, maximum 4294967295; blank uses the OS default). Environment scopes the configuration to a single Git branch under GitOps.
Connected Destinations. Select Send to Routes for conditional routing, filtering, and cloning via the Routing table, or QuickConnect for direct connections to one or more Destinations. For troubleshooting: the configuration modal's Live Data tab (Start Capture shows events as ingested) and Logs tab surface errors and warnings, and the Monitoring page charts volume and rate.
What the events look like
The docs page shows no rendered sample event, but the SNMP Trap Source documentation does list the internal, "meta" fields this Source uses. They are not part of an event, but Functions can use them to make processing decisions:
__didDecrypt: set totruefor every trap that is successfully decrypted.__final__inputId__snmpRaw: buffer containing the raw SNMP packet.__snmpVersion:0,2, or3, indicating SNMP v1, v2c, and v3.__srcIpPort: source IP and port separated by a pipe symbol._time
The format of __srcIpPort, per the docs:
event.__srcIpPort = ${rInfo.address}|${rInfo.port};
With Include varbind types on, the varbinds field parses to an array of objects like this:
[{oid: string, value: any, type: number}]
What the docs flag
- Cloud UDP throughput: large numbers of UDP events per second can cause Cribl.Cloud to drop data, a result of the UDP protocol's restrictions. The docs recommend a customer-managed (hybrid) Worker Group with Worker Nodes close to the UDP senders, plus OS UDP buffer tuning.
- Verbatim re-emit only: traps can be forwarded to other SNMP destinations, but the packet contents cannot be modified; they go out verbatim as they came in.
- One-way door: non-SNMP input data cannot be sent to SNMP destinations, so data from other inputs can't be pushed back out as traps.
- Smart mode is going away: before migrating off it, the docs advise monitoring queue usage, allocating disk space, draining the queues to avoid orphaned data, and verifying routing in a test environment.
- Socket buffer costs: setting the UDP socket buffer size affects OS memory utilization, and you may also need to raise the kernel SO_RCVBUF buffer per your operating system's documentation.
Frequently asked questions
Does the Cribl Stream SNMP Trap Source support TLS?
No. The SNMP Trap Source in Cribl Stream does not support TLS and has no Event Breaker support either. It is a Push type Source that receives traps over a UDP port, with a default of 162.
What SNMPv3 security levels can the Cribl Stream trap Source enforce?
Cribl Stream supports three levels of SNMPv3 security: user name checking without authentication, user authentication without privacy, and user authentication with privacy. Authentication protocols can be None, MD5, SHA1, SHA224, SHA256, SHA384, or SHA512, and privacy protocols can be None, AES128, AES256b, or AES2556r.
How are incoming SNMP traps handled by Cribl Stream?
Incoming traps can be forwarded to other SNMP destinations, but their contents cannot be modified and the packets are forwarded verbatim. The trap data can also be delivered to non-SNMP destinations such as Splunk, Syslog, or S3. Non-SNMP input data cannot be sent to SNMP destinations.
Which internal fields does the Cribl Stream SNMP Trap Source expose?
The Source exposes a set of internal fields, including __didDecrypt, __snmpRaw, __snmpVersion, __srcIpPort, __inputId, __final, and _time. These meta fields are not part of the event, but Functions can use them to make processing decisions.
Source
Verified against Cribl Stream 4.20 documentation on February 19, 2026.