From 234a035b97287d8910ca00a58b70a06775818693 Mon Sep 17 00:00:00 2001 From: Paul Lathrop Date: Thu, 15 Jan 2009 09:35:47 -0800 Subject: Fix #1560 Adds an rspec test which demonstrates #1560 and a custom 'process' method for the aliases provider to fix it. The default processing uses split() to break the line into records on the separator, which breaks if records can contain the separator. The custom method I've added uses a 'limited' split() to break the line on the first separator only. This commit fixes #1560 Signed-off-by: Paul Lathrop --- test/data/providers/mailalias/aliases/test1 | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 test/data/providers/mailalias/aliases/test1 (limited to 'test/data') diff --git a/test/data/providers/mailalias/aliases/test1 b/test/data/providers/mailalias/aliases/test1 new file mode 100644 index 000000000..20f90989f --- /dev/null +++ b/test/data/providers/mailalias/aliases/test1 @@ -0,0 +1,28 @@ +# Basic system aliases -- these MUST be present +MAILER-DAEMON: postmaster +postmaster: root + +# General redirections for pseudo accounts +bin: root +daemon: root +named: root +nobody: root +uucp: root +www: root +ftp-bugs: root +postfix: root + +# Put your local aliases here. + +# Well-known aliases +manager: root +dumper: root +operator: root +abuse: postmaster + +# trap decode to catch security attacks +decode: root + +# Other tests +anothertest: "|/path/to/rt-mailgate --queue 'another test' --action correspond --url http://my.com/" +test: "|/path/to/rt-mailgate --queue 'test' --action correspond --url http://my.com/" -- cgit