Project

General

Profile

Actions

Bug #14924

open

ipnat -f fails to parse newline after last rule

Added by Andrew Stone 4 months ago. Updated 4 months ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
-
Start date:
2022-08-20
Due date:
% Done:

0%

Estimated time:
Difficulty:
Medium
Tags:
Gerrit CR:
External Bug:

Description

When trying to load a simple nat config via ipnat -f , if there is a newline on the last line, parsing will fail.

$ pfexec ipnat -f config/ipnat.conf
syntax error error at "", line 1

The failing example (with a newline):
map igb0 192.168.3.0/24 -> 0/32 portmap tcp/udp 1025:65000
map igb0 192.168.3.0/24 -> 0/32 portmap

A successful example:
map igb0 192.168.3.0/24 -> 0/32 portmap tcp/udp 1025:65000
map igb0 192.168.3.0/24 -> 0/32 portmap
<-- No "\n"

Actions #1

Updated by Andrew Stone 4 months ago

  • Subject changed from ipnat -f fails to parse newlijne after last rule to ipnat -f fails to parse newline after last rule
Actions #2

Updated by Andrew Stone 4 months ago

  • Description updated (diff)
Actions #3

Updated by Andrew Stone 4 months ago

  • Description updated (diff)
Actions #4

Updated by Andrew Stone 4 months ago

  • Description updated (diff)
Actions #5

Updated by Andrew Stone 4 months ago

  • Description updated (diff)
Actions

Also available in: Atom PDF