Commit 3f79004
committed
pmrfc3164: accept IPv6 host tokens
Keep IPv6-based syslog sources interoperable in legacy RFC3164
pipelines without manual header cleanup.
Before: IPv6 literals in HOSTNAME stopped parsing and
After: IPv6 literals are accepted as HOSTNAME tokens.
Impact: fixes user-visible RFC3164 forwarding for IPv6 hosts.
Recognize IPv6 literals when the hostname scan hits a colon and
validate the full token with inet_pton before accepting it.
Honor permit.squarebracketsinhostname when brackets are present.
Consume the hostname token and trailing space to keep TAG parsing
in sync with RFC3164 expectations.
Add a regression test for IPv6 HOSTNAME parsing.
Tests: not run (not requested).
Fixes: rsyslog#3012
With the help of AI-Agents: GPT-5.2-Codex1 parent 3a7b661 commit 3f79004
2 files changed
+26
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
179 | 179 | | |
180 | 180 | | |
181 | 181 | | |
| 182 | + | |
182 | 183 | | |
183 | 184 | | |
184 | 185 | | |
| |||
2087 | 2088 | | |
2088 | 2089 | | |
2089 | 2090 | | |
| 2091 | + | |
2090 | 2092 | | |
2091 | 2093 | | |
2092 | 2094 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
0 commit comments