Syslog
Syslog sends log messages from devices and servers to a central collector. It is the backbone of most SIEM pipelines, and in its classic form it is unauthenticated, unencrypted and can silently drop messages.
- OSI layer
- 7 Application
- Carried in
- UDP, TCP, TLS
- Ports
- 514/udp, 514/tcp (common, not registered), 6514/tcp (TLS)
- Wireshark filter
syslog- Encrypted
- no
Packet structure
A syslog message is one line of text. The modern format (RFC 5424):
<165>1 2026-10-28T14:03:12.481Z fw01.example.com sshd 4123 ID47 [origin ip="10.0.0.1"] Failed password for root from 203.0.113.9 port 51022 ssh2
│ │ │ │ │ │ │ │ └ MSG: free text (UTF-8)
│ │ │ │ │ │ │ └ STRUCTURED-DATA: [id key="value" ...] or "-"
│ │ │ │ │ │ └ MSGID: message type, or "-"
│ │ │ │ │ └ PROCID: process ID, or "-"
│ │ │ │ └ APP-NAME
│ │ │ └ HOSTNAME
│ │ └ TIMESTAMP (RFC 3339, with time zone)
│ └ VERSION: 1
└ PRI: facility × 8 + severity (165 = 20 × 8 + 5 → local4.notice)
The older BSD format (RFC 3164), still sent by most network devices: <34>Oct 28 14:03:12 fw01 sshd[4123]: Failed password for root .... It has no year, no time zone and no structure beyond the tag.
| Severity | Name | Facility | Name |
|---|---|---|---|
| 0 | Emergency | 0 | kern |
| 1 | Alert | 1 | user |
| 2 | Critical | 3 | daemon |
| 3 | Error | 4 | auth |
| 4 | Warning | 10 | authpriv |
| 5 | Notice | 13 | log audit |
| 6 | Informational | 16–23 | local0–local7 (network devices, appliances) |
| 7 | Debug |
How it works
Devices and servers (the originators) send messages to a collector (rsyslog, syslog-ng, a SIEM agent), sometimes through relays. There is no handshake and no reply:
- UDP 514: fire and forget. One message per datagram; lost or spoofed messages go unnoticed.
- TCP: reliable delivery. Messages are framed by newline or by an octet count (
123 <165>1 ..., RFC 6587). - TLS 6514: TCP with encryption and, with client certificates, authentication of the sender (RFC 5425).
In Wireshark
| Filter | Shows |
|---|---|
syslog | Syslog over UDP 514 (and TCP if decoded) |
syslog.level <= 3 | Errors and worse |
syslog.facility == 4 || syslog.facility == 10 | Authentication messages |
syslog.msg contains "Failed password" | Search the message text |
udp.port == 514 && !syslog | Non-syslog traffic on the syslog port |
tcp.port == 6514 | Syslog over TLS |
For TCP on other ports use Decode As › Syslog.
What normal looks like: a steady stream from many devices to one or two collectors. A device that suddenly stops sending is as interesting as one that sends a burst: attackers disable logging or flood it. Syslog from outside the management network, or to an unknown collector, is suspicious.
Security notes
- Spoofing and log injection: UDP syslog has no authentication; anyone who can reach the collector can forge messages with any hostname, to hide activity or plant false evidence. Collectors should accept only expected sources, ideally over TLS with certificates.
- Clear text: logs contain user names, IP addresses, URLs and sometimes passwords typed into the user name field. Use TLS between sites.
- Message loss: UDP drops messages under load, and an attacker can flood the collector. Use TCP or TLS with queues for important sources.
- Log tampering on the host: an attacker with admin rights can stop the agent or delete local logs; shipping in real time to a separate collector protects the record.
- Parser attacks: crafted messages that break the SIEM’s parser (or exploit it, as Log4Shell did via logged strings) can hide events.
- Time: without NTP and time zones (RFC 3164 has none), timelines across devices do not line up.
Versions and related
- RFC 3164 (BSD syslog) documents the old format; RFC 5424 is the modern one, with transports in RFC 5426 (UDP), RFC 6587 (TCP) and RFC 5425 (TLS).
- CEF and LEEF are vendor formats carried inside syslog messages, common in SIEMs.
- Windows Event Forwarding and agents (Beats, Fluent Bit, OpenTelemetry) are alternatives for servers.
- Runs over UDP or TCP, with TLS. SNMP traps are the other way devices report events.